Home > php教程 > php手册 > PHP调用JAVA 需要认证的webservices

PHP调用JAVA 需要认证的webservices

WBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWB
Release: 2016-06-13 10:46:43
Original
1312 people have browsed it

根据官方文档一般是发送头信息,但是这个SOAP服务端不支持,最后是在new的时候发送了相关的参数才通过认证
PHP官方的实例基本都是下面这样子的代码,'authentication' => SOAP_AUTHENTICATION_BASIC 基本都少这行
这次遇到的问题主要是服务提供商没有说清楚具体的认证方式以及具体的参数,导致瞎折腾了一段时间。
其中:login和password参数是可以自定义的
 
帮助010203040506 $soapParams = array(             'login' => 'username' ,             'password' => 'password' ,             'authentication' => SOAP_AUTHENTICATION_BASIC         ); $client = new SoapClient('xxxx?wsdl', $soapParams);
 

source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Latest Issues
php data acquisition?
From 1970-01-01 08:00:00
0
0
0
PHP extension intl
From 1970-01-01 08:00:00
0
0
0
How to learn php well
From 1970-01-01 08:00:00
0
0
0
Popular Recommendations
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template