Jump to content

SOAP trouble - Parse error: syntax error, unexpected T_VARIABLE


strago

Recommended Posts

<?php
require_once('nusoap.php');
$soap_server = 'http://www.domain.com/api/api.cfc?wsdl';

$client = new soapclient($soap_server);
$client->call()

$params = array('user' => '[email protected]',  
                'password' => 'PASSWORD');

$return_string = $client->call('getKey', $params);
print_r($return_string);

$subId = 'XXXXXX';
$params = array('keyStr' => $keyStr,
               'subId' => $subId);
$return_string = $client->call('getTodaySubIDStats', $params);
print_r($return_string);

unset($client);

?>

 

spits out

 

Parse error: syntax error, unexpected T_VARIABLE in /home/site82/public_html/stats.php on line 12

 

Line 12 is...

 

$params = array('user' => '[email protected]', 

Gah, then it spits out

 

Fatal error: Uncaught SoapFault exception: [Client] Function ("call") is not a valid method for this service in /home/site82/public_html/stats.php:17 Stack trace: #0 /home/site82/public_html/stats.php(17): SoapClient->__call('call', Array) #1 /home/site82/public_html/stats.php(17): SoapClient->call('getKey', 'getTodaySubIDSt...', Array) #2 {main} thrown in /home/site82/public_html/stats.php on line 17

 

which is the error that I was trying to fix.

 

$return_string = $client->call('getKey','getTodaySubIDStats', $params);

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.