ich hab es nun noch einmal mit SOAP::Lite probiert, leider ohne Erfolg
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
use SOAP::Lite;
my $soap = SOAP::Lite->new( proxy => 'http://192.168.0.214/stockquote1.php');
$soap->on_action( sub { "urn:HelloWorld#sayHello" });
$soap->autotype(0)->readable(1);
my $som = $soap->call(
'CheckForSoftwareUpdates',
SOAP::Data->name('InstalledSoftware')->value(
\SOAP::Data->value([
SOAP::Data->name('SoftwareName')->value('SampleSoftware1'),
SOAP::Data->name('Version')->value('1.2.3'),
SOAP::Data->name('OperatingSystem')->value('Windows_XP'),
])
)
);
if ($som->fault)
{
die $som->fault->{ faultstring };
}
print $som->result, "\n";
Das Resultat:
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
<?xml version="1.0" encoding="UTF-8"?>
<soap:Envelope
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/"
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
soap:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"
xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
<soap:Body>
<CheckForSoftwareUpdates>
<InstalledSoftware>
<soapenc:Array>
<SoftwareName>SampleSoftware1</SoftwareName>
<Version>1.2.3</Version>
<OperatingSystem>Windows_XP</OperatingSystem>
</soapenc:Array>
</InstalledSoftware>
</CheckForSoftwareUpdates>
</soap:Body>
</soap:Envelope>
Der Teil '<soapenc:Array>' zu viel :(
Last edited: 2011-06-19 13:53:18 +0200 (CEST)