git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@163418 c90b9560-bf6c-de11-be94-00142212c4b1
This commit is contained in:
Dave Barr 2004-07-15 23:00:52 +00:00
parent d796253cd2
commit 9d0a1e7664

View file

@ -1,5 +1,5 @@
<?xml version='1.0' encoding='iso-8859-1'?>
<!-- $Revision: 1.4 $ -->
<!-- $Revision: 1.5 $ -->
<refentry id="function.is-soap-fault">
<refnamediv>
<refname>is_soap_fault</refname>
@ -34,10 +34,10 @@
<programlisting role="php">
<![CDATA[
<?php
$client = SoapClient("some.wsdl", array('exceptions' => 0));
$client = new SoapClient("some.wsdl", array('exceptions' => 0));
$result = $client->SomeFunction(...);
if (is_soap_fault($result)) {
trigger_error("SOAP Fault: (faultcode: {$result->faultcode}, faultstring: {$result->faulstring})", E_ERROR);
trigger_error("SOAP Fault: (faultcode: {$result->faultcode}, faultstring: {$result->faultstring})", E_ERROR);
}
?>
]]>
@ -49,10 +49,10 @@ if (is_soap_fault($result)) {
<![CDATA[
<?php
try {
$client = SoapClient("some.wsdl");
$client = new SoapClient("some.wsdl");
$result = $client->SomeFunction(...);
} catch (SoapFault $fault) {
trigger_error("SOAP Fault: (faultcode: {$fault->faultcode}, faultstring: {$fault->faulstring})", E_ERROR);
trigger_error("SOAP Fault: (faultcode: {$fault->faultcode}, faultstring: {$fault->faultstring})", E_ERROR);
}
?>
]]>