php - I am working for a project and I have to get data from a WSDL -


i confused on , appreciate if helps me.i working project , have data wsdl.this webservice url . url.http://203.109.97.241/axis/services/searchhoteldetails?wsdl first in xml integration.so dont know how data fronm url.i try country name way.

<?php $client = new soapclient("http://203.109.97.241/axis/services/searchhoteldetails?wsdl", array('soap_version'   => soap_1_2));  $something =  $client->gethoteldetailsxmlresponse(array("country"=>"india"));  echo "<pre>"; print_r($something); die(); ?> 

but cant result..any 1 pls me.

your using wrong method name.

actual method name gethoteldetailsxml

request call should :

$something =  $client->gethoteldetailsxml($xml_request); 

$xml_request request xml. (please xml document , assign variable.).

modified code:

<?php  $xml_request = "<hotelsearchrequest> <clientinfo> <companycode>companycode</companycode> <username>username</username> <password>password</password> </clientinfo> <hotelinfo> <country>india</country> <city>goa</city> <checkindate>20/04/2014</checkindate> <checkoutdate>21/04/2014</checkoutdate> <hotelname>thaj</hotelname> <norooms>2</norooms> <starrating/> <roomtype/> <responsetype>c</responsetype> <roominginfo> </hotelinfo> </hotelsearchrequest>";  $client = new soapclient("http://203.109.97.241/axis/services/searchhoteldetails?wsdl", array('soap_version'   => soap_1_2));  $something =  $client->gethoteldetailsxml($xml_request);  var_dump($something); die(); ?> 

Comments

Popular posts from this blog

amazon web services - S3 Pre-signed POST validate file type? -

c# - Check Keyboard Input Winforms -