Implement an Air API by sending a SOAP request

后端 未结 2 1715
难免孤独
难免孤独 2021-01-14 11:47

I have a php web site. Here I need to implement air ticket searching and booking functionality. In order to do this, I have used a paid API from ARZOO web site... I got all

2条回答
  •  情歌与酒
    2021-01-14 12:39

    Since they are mentioned standard SOAP client and you are sending the cURL request to the Server that will never give any response.

    $location_URL = "http://xx.xxx.xx.xxx/ArzooWS/services/DOMFlightAvailability";
    $action_URL ="http://com.arzoo.flight.avail";
    
    $client = new SoapClient('http://xx.xxx.xx.xxx/ArzooWS/services/DOMFlightAvailability?wsdl', array(
    'soap_version' => SOAP_1_1,
    'location' => $location_URL,
    'uri'      => $action_URL,
    'style'    => SOAP_RPC,
    'use'      => SOAP_ENCODED,
    'trace'    => 1,
    ));
    
    try
    {
        $result = $client->__call('getAvailability',array($req_int));
        $response= htmlentities($result);
    }
    

    You can use SOAP1.1 Request.

提交回复
热议问题