Мне нужно подключиться к веб-сервисам CEBroker SOAP в php. SOAP-запрос:
POST /CEBrokerWebService.asmx HTTP/1.1
Host: test.ws.cebroker.com
Content-Type: text/xml; charset=utf-8
Content-Length: length
SOAPAction: "http://www.cebroker.com/CEBrokerWebService/TestUploadXMLFile"
<?xml version="1.0" encoding="utf-8"?>
<soap:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
<soap:Body>
<TestUploadXMLFile xmlns="http://www.cebroker.com/CEBrokerWebService/" />
</soap:Body>
</soap:Envelope>
Это мой код,
<?php
$username = "xxxxxxxx";
$password = "xxxxxxxx";
$options = array(
"login" => $username,
"password" => $password,
'use' => SOAP_LITERAL
);
$client = new SoapClient('test.ws.cebroker.com//CEBrokerWebService.asmx?wsdl', $options);
echo "<pre>";
//print_r($client);die();
$response = $client->TestUploadXMLFile(array(
"licensee_profession" => 'Licensed Practical Nurse',
"licensee_number" => '6547852-25',
"cebroker_state" => 'AR',
"first_name" => 'Dalton',
"last_name" => 'Developer',
"date_completed" => '2017-04-06 22:52:16',
));
print_r($response);
Задача ещё не решена.
Других решений пока нет …