I have relatively no experience with SOAP. Im trying to work with a webservice for a client using WSDL mode. I'm having trouble passing parameters with the method and getting them to come the parameters to show up in the request as needed. I'm using the standard php soap class.
I need my SOAP request to be structured like the following:
<?xml version="1.0" encoding="UTF-8"?>
<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" xm lns:ns1="http://hostserver/"><SOAP-ENV:Body><ns1:DoLogin>
<ns1:request>
<ns1:Session><ns1:SessionId>00000000-0000-0000-0000-000000000000</ns1:SessionId></ns1:Session>
<ns1:UserCredential><ns1:UserName>username</ns1:UserName><ns1:Password>password</ns1:Password><ns1:ApplicationID>00000000-0000-0000-0000-000000000000</ns1:ApplicationID><ns1:ClientID>00000000-0000-0000-0000-000000000000</ns1:ClientID><ns1:ClientVersion>V1.0</ns1:ClientVersion></ns1:UserCredential>
</ns1:request>
</ns1:DoLogin></SOAP-ENV:Body></SOAP-ENV:Envelope>
In php I call the function like so:
$client->DoLogin($args);
And the request ends up like this:
<?xml version="1.0" encoding="UTF-8"?>
<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" xmlns:ns1="http://hostserver/"><SOAP-ENV:Body><ns1:DoLogin/></SOAP-ENV:Body></SOAP-ENV:Envelope>
No matter how I pass the args (single varabiables, array, class object) I cant get the request to have the structure as that.
Can anyone help me? I'm sure its going to be something quite simple.