Answer the question
In order to leave comments, you need to log in
How to implement SOAP client on Bitrix?
Help people ))
I have a working SOAP client code in PHP, now I need to convert this code into a Bitrix SOAP client.
<?php
$client = new SoapClient("http://rates.kazpost.kz/postratesws/postratesws.wsdl");
$result = $client->GetPostRate(
[
"MailInfo" => [
"Product" => "4",
"MailCat" => "1",
"SendMethod" => "1",
"Weight" => "14000",
"From" => "14",
"To" => "05"
]
]
);
echo $result->PostRate;
?>
<?
function TestComponent()
{
$client = new CSOAPClient("ws.strikeiron.com", "/relauto/iplookup/DNS");
$request = new CSOAPRequest( "DNSLookup", "http://tempuri.org/");
$request->addSOAPHeader( "LicenseInfo xmlns=\"http://ws.strikeiron.com\"",
array("UnregisteredUser" => array( "EmailAddress" => "[email protected]" ))
);
$request->addParameter("server", "www.yandex.ru");
$response = $client->send( $request );
echo "SOAPRequest: ".htmlspecialchars($client->getRawRequest());
echo "SOAPResponse: ".htmlspecialchars($client->getRawResponse());
}
?>
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question