Hi everyone,
I'm writing a NuSOAP client for a webservice whose wsdl is located at: http://mywebserver/eggsms/egg_sms.wsdl
I don't know what I'm doing wrong but I always get a wsdl error saying that the types are not supported
here is my code for the client:
require_once('lib/nusoap/NuSOAP.php');
include_once('lib/config.php');
$thisClient = new nusoapclient('http://mywebserver/eggsms/egg_sms.wsdl', true);
$thisClient->soap_defencoding = 'UTF-8';
$err = $thisClient->getError();
if($err) {
echo '<h2>Constructor Error: </h2><pre>'.$err.'</pre>';
}
$name = implode(' ', array($firstName, $lastName));
$proxy = $thisClient->getProxy();
$params = array( 'regName' => $name, 'regMSISDN' => $msisdn, 'regKey' => $EGG_API_key );
$result = $proxy->EGG_Offers_Reg($params);
//$result = $thisClient->call('EGG_Offers_Reg'
if ($proxy->fault) {
echo '<h2>Fault</h2><pre>';
print_r($result);
echo '</pre>';
} else {
// Check for errors
$err = $proxy->getError();
if ($err) {
// Display the error
echo '<h2>Error</h2><pre>' . $err . '</pre>';
} else {
// Display the result
echo '<h2>Result</h2>';
echo 'Result: SOAP Transaction completed!<br>';
print_r($result);
}
}
// Display the request and response
echo '<h2>Request</h2>';
echo '<pre>' . htmlspecialchars($proxy->request, ENT_QUOTES) . '</pre>';
echo '<h2>Response</h2>';
echo '<pre>' . htmlspecialchars($proxy->response, ENT_QUOTES) . '</pre>';
// Display the debug messages
echo '<h2>Debug</h2>';
echo '<pre>' . htmlspecialchars($proxy->debug_str, ENT_QUOTES) . '</pre>';
return $result['regReturn'];
|
Any help is greatky appreciated...
Thank you.