Hi All!
I'm apparently doing something very wrong here... I can't get my soap client to send the security certificate which a valid .pem file and because of that the subsequent calls are failing.
What do I have to do to get the soap client to send the pem file?
Thanks,
Pete
<?php
$wsdl = "open.wsdl";
// setup the transaction array
$header = array('local_cert' => "certificate.pem",
'logonUser' => "user_name",
'style' => SOAP_DOCUMENT,
'use' => SOAP_LITERAL,
'exceptions' => true,
'trace' => true);
// create the soap client, this will log us in
$client = new SoapClient($wsdl, $header);
try
{
$response = $client->getMessage($parameters);
}
catch (Exception $e)
{
dumpVars($client->__getLastRequest());
echo 'Caught exception: ', $e->getMessage(), "\n";
}
?>
Notice how none of the header info is being sent and no security certificate!
<?xml version="1.0" encoding="UTF-8"?>
<SOAP-ENV:Envelope
xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"
xmlns:ns1="http://domain.com/soap_request"
xmlns:ns2="http://domain.com/soap_request/">
<SOAP-ENV:Body>
<ns2:getMessageTypeDef>
<ns1:requestAPI>API_TYPE1</ns1:requestAPI>
<ns1:requestOperation>getMessageByDate</ns1:requestOperation>
</ns2:getMessageTypeDef>
</SOAP-ENV:Body>
</SOAP-ENV:Envelope>