Concerning the lack of webservice value, the younger brother asks for help to solve the problem.

Source: Internet
Author: User
No value is available for webservice. could you help me ;? Phpfunctiongetline () {& nbsp; $ clientnewSoapClient (www. ungb. comskyLineService. asmx? WSDL); & nbsp; try {& nbsp; $ result $ cl the webservice cannot be obtained. help me
Function getline (){
$ Client = new SoapClient ('http: // www.ungb.com/sky/LineService.asmx? WSDL ');
Try {
$ Result = $ client-> GetListLine ();
Print_r ($ result );
Return $ result;
} Catch (SoapFault $ e ){
Return-1;
}
}
?>
I obtained a null value through the above code, but I tested it with soapui. The interface is good and the value can be obtained.

I am depressed about this. please help me solve this problem. thank you ................

------ Solution --------------------
PHP code
define('R_P',dirname(__FILE__)."/");include_once(R_P.'class/nusoap/nusoap.php');$wsdl="http://www.ungb.com/sky/LineService.asmx?WSDL";$ParmArray=array("literal"=>"");$client = new nusoap_client($wsdl,true);$client->soap_defencoding = 'utf-8';$client->decode_utf8 = false;$client->xml_encoding = 'utf-8';$client->timeout = 900;$client->response_timeout = 900;$result = $client->call("GetListLine",array("parameters"=>$ParmArray));print_r($result); 

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.