Skip to content

Commit

Permalink
Re-arrange child elements of Fault XML to match SOAP 1.1 XSD
Browse files Browse the repository at this point in the history
Although the text specification of SOAP 1.1 only names the children
of the Fault element, the XSD at http://schemas.xmlsoap.org/soap/envelope/
defines them as a "sequence", implying a fixed order (faultcode,
faultstring, faultactor, detail).

Some clients, particularly using .NET, are reported to have issues
parsing the response if the elements don't match that order.

This was reported on Sourceforge as long ago as 2011:
https://sourceforge.net/p/nusoap/discussion/193579/thread/9a5aff36/
  • Loading branch information
IMSoP authored and f3l1x committed Oct 22, 2020
1 parent d3cc031 commit b713183
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/nusoap.php
Original file line number Diff line number Diff line change
Expand Up @@ -1105,8 +1105,8 @@ function serialize()
'<SOAP-ENV:Body>' .
'<SOAP-ENV:Fault>' .
$this->serialize_val($this->faultcode, 'faultcode') .
$this->serialize_val($this->faultactor, 'faultactor') .
$this->serialize_val($this->faultstring, 'faultstring') .
$this->serialize_val($this->faultactor, 'faultactor') .
$this->serialize_val($this->faultdetail, 'detail') .
'</SOAP-ENV:Fault>' .
'</SOAP-ENV:Body>' .
Expand Down

0 comments on commit b713183

Please sign in to comment.