如何将本地WSDL文件加载到SoapClient?
$wsdl = __DIR__.'/wsdl.wsdl';
$this->client = new SoapClient($wsdl);
$xsd = __DIR__.'/wsdl/xsd/xmldsig-core-schema.xsd';
Run Code Online (Sandbox Code Playgroud)
PHP致命错误:SOAP-ERROR:解析WSDL:在WSDL中找不到任何可用的绑定服务.
WSDL文件中XSD文件的相对路径: ./xsd/xmldsig-core-schema.xsd
<?xml version="1.0" encoding="UTF-8"?>
<wsdl:definitions xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" >
<wsdl:types>
</wsdl:definitions>
Run Code Online (Sandbox Code Playgroud)
在您的WSDL文件中
<soap:binding style="document" transport="https://schemas.xmlsoap.org/soap/https"/>
Run Code Online (Sandbox Code Playgroud)
应该
<soap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http"/>
Run Code Online (Sandbox Code Playgroud)
| 归档时间: |
|
| 查看次数: |
708 次 |
| 最近记录: |