Here is the entire code for my function:
Code: Select all
<?php
require_once('nusoap.php');
function TRECSend($a, $b, $c, $d, $e, $f)
{
$str = '<?xml version=\"1.0\" encoding=\"UTF-8\" ?><Transmission><EdProviderData><DetailData><Detail>';
$str = $str . '<IN_PROV>' . $a . '</IN_PROV> <IN_CRSE>' . $b. '</IN_CRSE> <IN_CDATE>' .$c . '</IN_CDATE> <IN_ZIP>' . $d . '</IN_ZIP>';
$str = $str . '<IN_LICENSE>' . $e . '</IN_LICENSE> <IN_NAME>' . $f . '</IN_NAME> </Detail> </DetailData> </EdProviderData> </Transmission>';
$wsdl="https://www.trec.state.tx.us/ProcessEdRoster/Service1.asmx?wsdl";
include 'TREC_DevToken.php';
$client=new soapclient($wsdl);
// create header object and insert into headers
// $header = new SoapHeader('https://www.trec.state.tx.us/ValidationSoapHeader/', 'DevToken', $DevToken, false);
$header = array(new SoapHeader('https://www.trec.state.tx.us/ValidationSoapHeader/', 'DevToken', $DevToken, false));
// $xmlReq = ('xmlReq' => $str);
$xmlReq = array('xmlReq' => $str);
try
{
$response = $client->__soapCall("ProcessRoster", $xmlReq, null, $header);
return $response;
}
catch (SoapFault $exception)
{
return $exception;
}
}
?>I don't see anything wrong. I did correct one variable earlier that was giving me the Object Reference. That was corrected on line 12.
Any help would be greatly appreciated.
Eddi Rae