$client=new soapclient('http://xxx.xxxx.xxx:8099/mlf_webservice/publicrequest?wsdl',array('encoding'=>'utf-8'));
//$client->soap_defencoding = 'utf-8';
$authvalues = new soapvar(array('username'=>'username','password'=>'password'),soap_enc_object);
$header = new soapheader('http://xxx.xxx.xxx:8099/mlf_webservice/publicrequest?wsdl', 'authrity', $authvalues,false);
$client->__setsoapheaders($header);
$post_data= '{\"version\":\"10\",\"messagetype\":\"querystorelist\",\"signvalue\":\"4\"}';//接口参数必须是json格式
$suc = $client->publicrequest($post_data);
总是报错,请高手指点
请给出真实的测试账号
请给出真实的测试账号
但这样的提示,你如何解释?
Fatal error: Uncaught SoapFault exception: [soap:Server] 用户名格式不对 in ......
但这样的提示,你如何解释?
Fatal error: Uncaught SoapFault exception: [soap:Server] 用户名格式不对 in ......
[soap:Server] 表示异常来自服务端
显然是 用户名密码不对
[soap:Server] 表示异常来自服务端
显然是 用户名密码不对
[soap:Server] 表示异常来自服务端
显然是 用户名密码不对
[soap:Server] 表示异常来自服务端
显然是 用户名密码不对
PHP怎么学习?PHP怎么入门?PHP在哪学?PHP怎么学才快?不用担心,这里为大家提供了PHP速学教程(入门到精通),有需要的小伙伴保存下载就能学习啦!
Copyright 2014-2025 https://www.php.cn/ All Rights Reserved | php.cn | 湘ICP备2023035733号