I am having problems converting from Pear SOAP to
PHP5 SOAP, especially when it comes to complex types.
I would be grateful for any help on how this should be
translated:
require_once("S OAP/Client.php");
$wsdlurl = "http://myserver/myservices/mypage.php?wsdl ";
$wsdl = new SOAP_WSDL($wsdl url, array("timeout" => 360));
$soapclient = $wsdl->getProxy();
$soapclient->setEncoding("U TF-8");
$soapclient->__trace(1);
$mydata = array(
"fromDate" => new SOAP_Value("fro mDate", "string", "2003-10-01"),
"toDate" => new SOAP_Value("toD ate",
"string", "2004-02-31"));
$args = array(
"myId" => new SOAP_Value("myI d","int", 1),
"criteria" => new SOAP_Value("cri teria", "{urn:engine}my Data", $mydata),
"start" => new SOAP_Value("sta rt","int", 0),
"limit" => new SOAP_Value("lim it","int", 20));
$res = $soapclient->searchData($ar gs);
if(PEAR::isErro r($res)) {
echo "Error: ".$res->getMessage()." \n";
} else {
echo "\nRes:\n";
print_r($res);
echo "\n";
}
Any ideas?
Regards,
Henrik
PHP5 SOAP, especially when it comes to complex types.
I would be grateful for any help on how this should be
translated:
require_once("S OAP/Client.php");
$wsdlurl = "http://myserver/myservices/mypage.php?wsdl ";
$wsdl = new SOAP_WSDL($wsdl url, array("timeout" => 360));
$soapclient = $wsdl->getProxy();
$soapclient->setEncoding("U TF-8");
$soapclient->__trace(1);
$mydata = array(
"fromDate" => new SOAP_Value("fro mDate", "string", "2003-10-01"),
"toDate" => new SOAP_Value("toD ate",
"string", "2004-02-31"));
$args = array(
"myId" => new SOAP_Value("myI d","int", 1),
"criteria" => new SOAP_Value("cri teria", "{urn:engine}my Data", $mydata),
"start" => new SOAP_Value("sta rt","int", 0),
"limit" => new SOAP_Value("lim it","int", 20));
$res = $soapclient->searchData($ar gs);
if(PEAR::isErro r($res)) {
echo "Error: ".$res->getMessage()." \n";
} else {
echo "\nRes:\n";
print_r($res);
echo "\n";
}
Any ideas?
Regards,
Henrik