Hi all,
The following code is working great in one server but it does not show results in another (blank page).
The different with the servers is that the one that don't show results has a proxy connection.
How do I have to modify the code for the second server to show results?, or where do I have to look for the problem? I'm clueless
Thanks a lot!
<?php
require_once('lib/nusoap.php');
require_once('lib/class.wsdlcache.php');
$clientID = 38;
$channelID = 51;
$playlistID = 77;
$webservice_username = "user";
$webservice_password = "pass";
$webServiceURL ="http://www.server.net/2.1/server.asmx?WSDL";
$client = new nusoap_client($webServiceURL, 'wsdl');
/* create the proxy object */
$proxy = $client->getProxy();
$err = $proxy->getError();
if ($err) {
echo '<h2>Constructor error</h2><pre>' . $err . '</pre>';
}
$session_header = "<UserCredentials xmlns='http://vidzapper.net/Webservice/'><Userid>".$webservice_username."</Userid><Password>".$webservice_password."</Password></UserCredentials>";
$proxy->setHeaders($session_header);
$params = array('clientID'=> $clientID, 'channelID'=> $channelID, 'playlistID'=>$playlistID);
$results = $proxy->call('SelectContentByPlaylistID', $params);
try{
// Check for a fault
if ($soapCall->fault) {
echo '<h2>Fault</h2><pre>';
print_r($results);
echo '</pre>';
die;
}
echo '<h2>Result</h2><pre>';
print_r($results);
echo '</pre>';
die;
} catch (SoapFault $exception) {
echo '<h2>Exception</h2><pre>';
print_r($exception);
echo '</pre>';
die;
}
?> |