Bug #75325 [Opn->Fbk]: SOAP-ERROR: Encoding: External reference ''

From: Date: Tue, 23 Mar 2021 14:39:39 +0000
Subject: Bug #75325 [Opn->Fbk]: SOAP-ERROR: Encoding: External reference ''
References: 1  Groups: php.bugs 
Request: Send a blank email to php-bugs+get-232938@lists.php.net to get a copy of this message
Edit report at https://bugs.php.net/bug.php?id=75325&edit=1 ID: 75325 Updated by: cmb@php.net Reported by: peter_liang at vtech dot com Summary: SOAP-ERROR: Encoding: External reference '' -Status: Open +Status: Feedback Type: Bug Package: SOAP related Operating System: CentOS 7.3 PHP Version: 7.0.24 -Assigned To: +Assigned To: cmb Block user comment: N Private report: N New Comment: > Not sure why the SoapFault exception still throws even request > and response are correct. Are they? The error message hints at an unescaped & (ampersand) in the response. Please double-check whether that is the case. Also check the behavior with any of the actively supported PHP versions[1]? [1] <php.net/supported-versions.php> Previous Comments: ------------------------------------------------------------------------ [2017-10-06 06:38:27] peter_liang at vtech dot com Seems the issue has existed since PHP 5.2. https://stackoverflow.com/questions/2004860/soap-error-encoding-external-reference-in-php ------------------------------------------------------------------------ [2017-10-06 04:40:57] peter_liang at vtech dot com Description: ------------ I have a webservice which was created by Java, when I use SoapClient to invoke it, it throws a SoapFault exception which says: SOAP-ERROR: Encoding: External reference ''. However, $soap->__getLastRequest() and $soap->__getLastResponse() return the correct XML - the same as I did using SoapUI. Here is the request and response XMLs for references. 1) Request XML. <ns1:checkEligibility><caller-id>XXXXX</caller-id><cust-key>1234456</cust-key><device-serial-num/><package id="12345-54321" productId="prod12345-54321"/><package id="54321-12345" productId="prod54321-12345"/></ns1:checkEligibility> 2) Response XML <ns2:checkEligibilityResponse><package-eligibility> <package status="1" href="" checksum="" name="" id="12345-54321"/><result description="This package is not defined in CRM" reason="checkout.undefined.package" status="block"/> </package-eligibility> <package-eligibility><package status="1" href="" checksum="" name="" id="54321-12345"/><result description="This package is not defined in CRM." reason="checkout.undefined.package" status="block"/></package-eligibility></ns2:checkEligibilityResponse> Not sure why the SoapFault exception still throws even request and response are correct. ------------------------------------------------------------------------ -- Edit this bug report at https://bugs.php.net/bug.php?id=75325&edit=1

« previous php.bugs (#232938) next »