How to reproduce an XML Request via SOAP
Posted: Fri Mar 14, 2008 7:31 am
Hi.
I've got this SOAP request structure I must comply in my petition:
and I wrote in my PHP code
but I generate this request message:
Which code must I write in PHP to reproduce the XML request I need?
Thank you very much.
I've got this SOAP request structure I must comply in my petition:
Code: Select all
<soap:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
<soap:Body>
<isValidUser xmlns="http://lab.domain.com/">
<userId>int</userId>
<lastName>string</lastName>
</isValidUser>
</soap:Body>
</soap:Envelope>
Code: Select all
$params = array('userId' => '5555', 'lastName' => 'Smith');
$response = $client->__soapCall("isValidUser", $params);
Code: Select all
<SOAP-ENV:Body>
<ns1:isValidUser/>
<param1>Smith</param1>
</SOAP-ENV:Body>
</SOAP-ENV:Envelope>
Thank you very much.