Jump to content

SOAP - Prb connecting to webservice and getting the output


mukunthan

Recommended Posts

Hi all,

 

I need to consume this webservice

https://www.apta.org/AM/APTAAPPS/ComponentAuthWebService/aptamemberauthorize.cfc?WSDL

 

It must return me an xml output. But I am  an error stating "HTTP-Could not connect to host ". I don't know where I am  going  wrong. Please help me sort this out. 

 

$arguments = array(
   'mausername'=> '22586',
   'mapassword' => 'swisher',
   'componenttype' => 'Section',
   'components'=> 'L',
   'authusername' => 'heart',
   'authpassword' => 'lung',
   'authpagealias' => 'Login'

);
$client = new SoapClient('https://www.apta.org/AM/APTAAPPS/ComponentAuthWebService/aptamemberauthorize.cfc?WSDL');

// Call RemoteFunction ()
$error = 0;

try {
   $result = $client->__soapCall('MemberAuth', $arguments);

} catch (SoapFault $fault) {
   $error = 1;
   echo 'Returned the following ERROR: ' .$fault->faultcode . '-' . $fault->faultstring ; 
}
print_r($result);
// kill object
unset($client);

 

Thanx in advance

 

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.