Dealing with indistinct complex type definiton in existing WSDL
| From: | jt | Date: | Sun, 01 Oct 2006 22:40:39 +0000 |
| Subject: | Dealing with indistinct complex type definiton in existing WSDL | ||
| Groups: | php.soap | ||
| Request: | Send a blank email to php-soap+get-2375@lists.php.net to get a copy of this message | ||
I have been attempting to create a SOAP client to consume services generated by an established server. When making use of any function which retrieves information as anything except single values, I encounter an error:
*"SOAP-ERROR: Encoding: object hasn't 'schema' property"*
Obtaining the function and type information from an existing SOAP server via:
$client = new SoapClient($wsdlUrl, $opts);
$reply = $client->__getFunctions();
var_dump($reply);
print "\n\n";
$reply = $client->__getTypes();
var_dump($reply);
print "\n\n";
Generates:
... [2]=> string(59) "GetCountriesResponse GetCountries(GetCountries $parameters)" ... [4]=> string(47) "struct GetCountries { ds ds; string status; }" [5]=> string(46) "struct ds { <anyXML> schema; <anyXML> any; }" [6]=> string(55) "struct GetCountriesResponse { ds ds; string status; }" [7]=> string(46) "struct ds { <anyXML> schema; <anyXML> any; }" ... From what I can learn of the implementation of the server, this "ds" structure is very similar to ADOdb's /*ADORecordSet */structure, or more exactly the fields hash array of the record set.The question is: How does one make use of the *SoapVar *call to construct an appropriate schema / type definition to keep the SOAP extension happy? Deepest thanks, JT McDuffie