Hey everyone, I have been trying diligently for 2 days to get this to work before asking for any help. I'm trying to create a PHP NuSOAP request similiar to this:
POST
https://global.marketing.ews.yahooapis.com/services/V4/LocationService
HTTP/1.0
Content-Type: text/xml; charset=utf-8
Content-Length: 987
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"
xmlns:wsse="http://schemas.xmlsoap.org/ws/2002/07/secext"
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns="http://marketing.ews.yahooapis.com/V4">
<soapenv:Header>
<wsse:Security>
<wsse:UsernameToken>
<wsse:Username>user</wsse:Username>
<wsse:Password>password</wsse:Password>
</wsse:UsernameToken>
</wsse:Security>
<license>35cf33e7-5ad1-3aa9-0593-346681f64eb0</license>
<masterAccountID>9901672</masterAccountID>
</soapenv:Header>
<soapenv:Body>
<getMasterAccountLocation/>
</soapenv:Body>
</soapenv:Envelope>
|
Does anyone have any ideas how to set this up, I think the wsse:Security part in the headers is what I just can't seem to get working correctly! Any help, would be much appreciated, thanks for helping me out, I truly appreciate this, I've been stuck for so long and tried to search before posting!
If someone could help me with the PHP syntax for forming the correct NuSoap Request, I'd be in debt to you!
--
I've tried something like this but had no results:
$client = new soapclient('https://global.marketing.ews.yahooapis.com/services/V4/LocationService?wsdl',true);
$security = array('Username'=>'me','Password'=>'pass');
$params = array('Security'=>$security,'license'=>'35cf33e7-5ad1-3aa9-0593-346681f64eb0','masterAccountID'=>'9901672');
$response = $client->call('LocationService',$params); |