About WebService get the value, the younger brother asks to help to solve the thought

Source: Internet
Author: User
Tags wsdl
About WebService get the value, little brother ask for help
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 get the null value through the above code, but I use the SOAPUI test, the interface is good, you can get the value.

This thing made me depressed to die, beg that elder brother to help solve, 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 = $client; Response_timeout =, $result = $client->call ("Getlistline", Array ("parameters" and "= $ParmArray)");p Rint_r ($ result); 
  • Related Article

    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.