2012-09-25 3 views
1
내가 catch되지 않은 SOAPFault의 예외와 오류를 데

발견 : [HTTP] 여기 SOAP의 HTTP하지

를 찾을 수 없음 WSDL 여기 내 코드

$client = new SOAPClient ('http://torcache.net/torcache.wsdl'); 
$infoHash = $client->cacheTorrent(base64_encode(file_get_contents('my.torrent'))); 

하고있다

<?xml version='1.0' encoding='UTF-8' ?> 
<definitions name='Cache' 
    targetNamespace='urn:Torcache' 
    xmlns:tns='urn:Torcache' 
    xmlns:soap='http://schemas.xmlsoap.org/wsdl/soap/' 
    xmlns:xsd='http://www.w3.org/2001/XMLSchema' 
    xmlns:soapenc='http://schemas.xmlsoap.org/soap/encoding/' 
    xmlns:wsdl='http://schemas.xmlsoap.org/wsdl/' 
    xmlns='http://schemas.xmlsoap.org/wsdl/'> 

<message name='cacheTorrentRequest'> 
    <part name='torrent' type='xsd:string'/> 
</message> 

<message name='cacheTorrentResponse'> 
    <part name='Result' type='xsd:string'/> 
</message> 

<portType name='CachePortType'> 
    <operation name='cacheTorrent'> 
    <input message='tns:cacheTorrentRequest'/> 
    <output message='tns:cacheTorrentResponse'/> 
    </operation> 
</portType> 

<binding name='CacheBinding' type='tns:CachePortType'> 
    <soap:binding style='rpc' 
    transport='http://schemas.xmlsoap.org/soap/http'/> 

    <operation name='cacheTorrent'> 
    <soap:operation soapAction='urn:xmethods-delayed-quotes#cacheTorrent'/> 
    <input> 
     <soap:body use='encoded' namespace='urn:xmethods-delayed-quotes' 
     encodingStyle='http://schemas.xmlsoap.org/soap/encoding/'/> 
    </input> 
    <output> 
     <soap:body use='encoded' namespace='urn:xmethods-delayed-quotes' 
     encodingStyle='http://schemas.xmlsoap.org/soap/encoding/'/> 
    </output> 
    </operation> 
</binding> 

<service name='CacheService'> 
    <port name='CachePort' binding='CacheBinding'> 
    <soap:address location='http://torcache.net/api/soap/'/> 
    </port> 
</service> 
</definitions> 

내 서버 통계

PHP 버전 5.3.15

이 오류가 발생하는 이유는 무엇입니까? 나는 그들의 api 페이지에서이 샘플 스크립트를 가지고있다. https://torcache.net/api

답변

0

나는 원격 Wsdl을 PHP의 soapclient로로드 한 적이 없다. 테스트하려면 wsdl을 로컬 파일로 다운로드하고 URL 대신 루트 '/'에서 절대 파일 경로를 사용하십시오. 그것이 잘 작동한다면, 나는 당신이 적어도 당신의 실수가 아니라는 것을 확신 할 것이다. 그러나 그것이 도서관의 버그라고 확신한다. 나는 PHP 개발자 세계에서 아무도 비누에 관심이 없으며 아무도이 문제를 해결하지 못한다고 생각합니다. 아니면 그냥 우리가 뭔가를 분명히 누락되었습니다.

당신이 오래된 nusoap 라이브러리의 복사본을 찾을 수 있습니다 - 당신이 아무런 문제없이 원격 wsdls를로드합니다.

+0

답변 해 주셔서 감사합니다. –

관련 문제