ksmatthews Posted January 24, 2010 Share Posted January 24, 2010 Hi All, I am running a CLI script written in PHP to execute a remote web service. THe service calls a method 'GetUKLocationByCounty($param)' which returns XML. I keep getting an error when I pass a string to this method, as required. Here is part of the code ... $client = new SoapClient('http://www.webservicex.net /uklocation.asmx?wsdl', array('trace' => 1 )); // call method $response = $client->GetUKLocationByCounty('Cornwall'); // get last soap response echo $client->__getLastResponse(); The web service can be found at : http://www.webservicex.net/WCF/ServiceDetails.aspx?SID=28 RESULT: PHP Fatal error: Uncaught SoapFault exception: [soap:Server] System.Web.Services.Protocols.SoapException: Server was unable to process request. ---> System.Data.SqlClient.SqlException: Procedure or function 'GetUKLocationByCounty' expects parameter '@County', which was not supplied. at WebServicex.UKLocation.GetUKLocationByCounty(String County) --- End of inner exception stack trace --- in /home/steven/public_html/XML-load/soap_test2.php:16 Any ideas ? regards, Steven Matthews Link to comment https://forums.phpfreaks.com/topic/189631-web-services-with-soap/ Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.