> 백엔드 개발 > PHP 튜토리얼 > 国政通的接口soapclient不成功

国政通的接口soapclient不成功

WBOY
풀어 주다: 2016-06-23 13:59:08
원래의
919명이 탐색했습니다.

如题

具体情况是我有一台生产机一台测试机  生产机上一切正常 测试机上

$soap = new SoapClient ("http://gboss.id5.cn/services/QueryValidatorServices?wsdl" );
로그인 후 복사

就不成功

漫长的等待后提示:

SoapFault exception: [WSDL] SOAP-ERROR: Parsing WSDL: Couldn't load from 'http://gboss.id5.cn/services/QueryValidatorServices?wsdl' 
로그인 후 복사


测试机和生产机环境基本上一致 soap扩展都开了


回复讨论(解决方案)

你的 url 对吗?怎么连浏览器也访问不到?

直接访问的结果是

This XML file does not appear to have any style information associated with it. The document tree is shown below.<wsdl:definitions xmlns:apachesoap="http://xml.apache.org/xml-soap" xmlns:impl="http://app.service.validator.businesses.gboss.id5.cn" xmlns:intf="http://app.service.validator.businesses.gboss.id5.cn" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns:wsdlsoap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" targetNamespace="http://app.service.validator.businesses.gboss.id5.cn"><!--WSDL created by Apache Axis version: 1.4Built on Apr 22, 2006 (06:55:48 PDT)--><wsdl:types><schema xmlns="http://www.w3.org/2001/XMLSchema" elementFormDefault="qualified" targetNamespace="http://app.service.validator.businesses.gboss.id5.cn"><element name="querySingle"><complexType><sequence><element name="userName_" type="xsd:string"/><element name="password_" type="xsd:string"/><element name="type_" type="xsd:string"/><element name="param_" type="xsd:string"/></sequence></complexType></element><element name="querySingleResponse"><complexType><sequence><element name="querySingleReturn" type="xsd:string"/></sequence></complexType></element><element name="queryBatch"><complexType><sequence><element name="userName_" type="xsd:string"/><element name="password_" type="xsd:string"/><element name="type_" type="xsd:string"/><element name="param_" type="xsd:string"/></sequence></complexType></element><element name="queryBatchResponse"><complexType><sequence><element name="queryBatchReturn" type="xsd:string"/></sequence></complexType></element></schema></wsdl:types><wsdl:message name="queryBatchResponse"><wsdl:part element="impl:queryBatchResponse" name="parameters"/></wsdl:message><wsdl:message name="queryBatchRequest"><wsdl:part element="impl:queryBatch" name="parameters"/></wsdl:message><wsdl:message name="querySingleResponse"><wsdl:part element="impl:querySingleResponse" name="parameters"/></wsdl:message><wsdl:message name="querySingleRequest"><wsdl:part element="impl:querySingle" name="parameters"/></wsdl:message><wsdl:portType name="QueryValidatorServices"><wsdl:operation name="querySingle"><wsdl:input message="impl:querySingleRequest" name="querySingleRequest"/><wsdl:output message="impl:querySingleResponse" name="querySingleResponse"/></wsdl:operation><wsdl:operation name="queryBatch"><wsdl:input message="impl:queryBatchRequest" name="queryBatchRequest"/><wsdl:output message="impl:queryBatchResponse" name="queryBatchResponse"/></wsdl:operation></wsdl:portType><wsdl:binding name="QueryValidatorServicesSoapBinding" type="impl:QueryValidatorServices"><wsdlsoap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http"/><wsdl:operation name="querySingle"><wsdlsoap:operation soapAction=""/><wsdl:input name="querySingleRequest"><wsdlsoap:body use="literal"/></wsdl:input><wsdl:output name="querySingleResponse"><wsdlsoap:body use="literal"/></wsdl:output></wsdl:operation><wsdl:operation name="queryBatch"><wsdlsoap:operation soapAction=""/><wsdl:input name="queryBatchRequest"><wsdlsoap:body use="literal"/></wsdl:input><wsdl:output name="queryBatchResponse"><wsdlsoap:body use="literal"/></wsdl:output></wsdl:operation></wsdl:binding><wsdl:service name="QueryValidatorServicesService"><wsdl:port binding="impl:QueryValidatorServicesSoapBinding" name="QueryValidatorServices"><wsdlsoap:address location="http://gboss.id5.cn/services/QueryValidatorServices"/></wsdl:port></wsdl:service></wsdl:definitions>
로그인 후 복사

你参考下这个看行不行?

经多次访问尝试,确认该 url 不可访问
若你处可以访问,则可能他限制了访问来源或 dns 没有传递到


我们都打不开阿 是不是对外网作了限制?防火墙?

经多次访问尝试,确认该 url 不可访问
若你处可以访问,则可能他限制了访问来源或 dns 没有传递到


我们都打不开阿 是不是对外网作了限制?防火墙?

非常感谢两位的帮助  我分析可能是国政通的接口限制了IP  之前没有考虑到这一点 

원천:php.cn
본 웹사이트의 성명
본 글의 내용은 네티즌들의 자발적인 기여로 작성되었으며, 저작권은 원저작자에게 있습니다. 본 사이트는 이에 상응하는 법적 책임을 지지 않습니다. 표절이나 침해가 의심되는 콘텐츠를 발견한 경우 admin@php.cn으로 문의하세요.
인기 튜토리얼
더>
최신 다운로드
더>
웹 효과
웹사이트 소스 코드
웹사이트 자료
프론트엔드 템플릿