我有一个 php 网站。这里我需要实现机票搜索和预订功能。为了做到这一点,我使用了来自 ARZOO 网站的付费 API……我从 ARZOO 获得了所有文档。我已经阅读了整个文档。医生说
"Accessing this service requires standard SOAP client. SOAP client should authenticate
itself through user name and password. Client should get their IPs registered with
Arzoo and get a user account created. The Arzoo web service provides a service
point URL. Web service clients should post SOAP request message as an attachment
for the desired response. The XML structure of different web services is discussed in
the respective documents."
You can connect to Arzoo XML services with the following test service point URLs:-
FlightAvailability:http://<url>/DOMFlightAvailability?wsdl
我认为需要通过肥皂发送请求是吗?但在空气可用性包含
Example Request Xml
<Request>
<Origin>BOM</Origin>
.............
.............
</Request>
我使用了以下代码
$post_string.="<Request>";
$post_string.="<Origin>$from</Origin><Destination>$to</Destination>";
........
......
$post_string.="</Request>";
$path = ":http://<url>/DOMFlightAvailability?wsdl";
$ch = curl_init($path);
curl_setopt($ch, CURLOPT_POSTFIELDS, $post_string); //Send the data to the file
curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
curl_setopt($ch, CURLOPT_HEADER, 0);
curl_setopt($ch, CURLOPT_HTTPHEADER, $headers);
$val = curl_exec($ch);
$headers = curl_getinfo($ch);
$errr=curl_error($ch);
但它没有给出任何结果。文件说
RESPONSE XML:-
The response will be in <arzoo_response> </arzoo_response>. This contains the Request
also.
我不知道肥皂。
我完全失望了。请帮我。我想我会在发布请求后得到一个 xml 响应。但是我将如何发布我的数据?
请回复
非常感谢,如果有人帮助我,非常感谢