Posted by J.O. Aho on 12/03/07 13:14
I have been working with a SOAP that uses the built in SOAP in PHP5.
The soap works as it should, as long as I run it on my local machine, on one
of the official servers or my private server at home, on the server on which
it's supposed to run, the result comes out in the wrong format. The only
difference with the servers as I can see is that the supposed server has
coldfusion configured, while the others don't. I'm completely lost what may be
wrong.
This is how it supposed to come out:
array(14) {
....
[9]=>
array(2) {
["gate"]=>
string(3) "S07"
["name"]=>
string(6) "PADDAN"
}
....
}
This is how it comes out on the supposed server:
object(stdClass)#2 (1) {
["item"]=>
array(14) {
....
[9]=>
object(stdClass)#30 (1) {
["item"]=>
array(2) {
[0]=>
object(stdClass)#31 (2) {
["key"]=>
string(4) "gate"
["value"]=>
string(3) "S07"
}
[1]=>
object(stdClass)#32 (2) {
["key"]=>
string(4) "name"
["value"]=>
string(6) "PADDAN"
}
}
}
....
}
The files on all the machines are the same.
The wsdl looks like this (this is a cut down version):
<?xml version='1.0' encoding='UTF-8' ?>
<definitions name='gp_soap'
targetNamespace='urn:gp_soap'
xmlns:tns='urn:gp_soap'
xmlns:soap='http://schemas.xmlsoap.org/wsdl/soap/'
xmlns:xsd='http://www.w3.org/2001/XMLSchema'
xmlns:soapenc='http://schemas.xmlsoap.org/soap/encoding/'
xmlns:wsdl='http://schemas.xmlsoap.org/wsdl/'
xmlns='http://schemas.xmlsoap.org/wsdl/'>
<message name='getGatesRequest'>
<part name='upc' type='xsd:array'/>
</message>
<message name='getGatesResponse'>
<part name='Result' type='xsd:array'/>
</message>
<portType name='gotpass_soapPortType'>
<operation name='getGates'>
<input message='tns:getGatesRequest'/>
<output message='tns:getGatesResponse'/>
</operation>
</portType>
<binding name='gp_soapBinding' type='tns:gp_soapPortType'>
<soap:binding style='rpc'
transport='http://schemas.xmlsoap.org/soap/http'/>
<operation name='getGates'>
<soap:operation soapAction='urn:xmethods-delayed-quotes#getGates'/>
<input>
<soap:body use='encoded' namespace='urn:xmethods-delayed-quotes'
encodingStyle='http://schemas.xmlsoap.org/soap/encoding/'/>
</input>
<output>
<soap:body use='encoded' namespace='urn:xmethods-delayed-quotes'
encodingStyle='http://schemas.xmlsoap.org/soap/encoding/'/>
</output>
</operation>
</binding>
<service name='gp_soapService'>
<port name='gp_soapPort' binding='gp_soapBinding'>
<soap:address location='http://localhost/~g/gp_soap.php'/>
</port>
</service>
</definitions>
--
//Aho
[Back to original message]
|