/ Published in: PHP
Mockup of how to create a SessionContext using PHP SOAP and ClientServices 2
Expand |
Embed | Plain Text
Copy this code and paste it in your HTML
$client = new SoapClient("http://cs2.acme.com/SessionService.svc?wsdl", $createSessionContextParameters->IpAdress = '127.0.0.1'; $createSessionContextParameters->ClientType = 'web_browser'; $createSessionContextParameters->Referrer = ''; $createSessionContextParameters->OperatorOverride = 'abc12345def67'; $createSessionContextParameters->ServiceID = 123; $createSessionContextParameters->RegionOverride = ''; $createSessionContextParameters->LanguageOverride = ''; try{ } catch(SoapFault $fault){ trigger_error("ERROR: (faultcode: {$fault->faultcode}, faultstring: {$fault->faultstring})", E_USER_ERROR); } $sessionContext = $response->CreateSessionContextResult;