SOAP on php v5.2.4
am 21.11.2007 17:10:43 von tommy123
I want to use SOAP on php v5.2.4. In previous version of php, I use
nusoap to develop SOAP but it seems not workable in v5.2 or later.
What is the formal method for doing SOAP in php? or, any good
framework to do it? Please advise. Thx.
Re: SOAP on php v5.2.4
am 24.11.2007 10:39:31 von petersprc
Hi,
You can use the SOAP extension described at php.net/soap.
To enable it, you can configure PHP with --enable-soap=shared and add
extension=soap.so to your php.ini. When activated, you'll see it in
your phpinfo output.
Here's a typical example with debugging:
$sc = new SoapClient('http://example.net/ws.wsdl', array('trace' =>
true));
$params = array('x' => 1, 'y' => 2);
$res = $sc->SomeMethod($params);
echo "SOAP trace: Request:\n\n" . $sc->__getLastRequest() .
"\nResponse:\n\n" . $sc->__getLastResponse() . "\n";
Regards,
John Peters
On Nov 21, 11:10 am, tommy...@gmail.com wrote:
> I want to use SOAP on php v5.2.4. In previous version of php, I use
> nusoap to develop SOAP but it seems not workable in v5.2 or later.
>
> What is the formal method for doing SOAP in php? or, any good
> framework to do it? Please advise. Thx.