It seems that if my WSDL source goes offline SOAPClient() creates
un-trappable fatal errors. I don't think this is right. Shouldn't this
be, at very least, trappable exceptions? This is the internet...
things go down, connections are dropped....... right??
What am i doing wrong?
<?php
ini_set('default_socket_timeout', 10); //set the socket timeout lower
then the execution timeout for this page.
try {
$commandServiceClient = new
SOAPClient(http://www.somevolitileserverthatsdo...test.wsdl?WSDL,
array('exceptions' => 0, "trace" => 1));
} catch(exception $e) {
exit("oopsie!!");
}
?>
Expected:
oopsie!!!
Actual output:
Fatal error: SOAP-ERROR: Parsing WSDL: Couldn't load from
'http://www.somevolitileserverthatsdownrightnow.com/test.wsdl?WSDL' in
D:\Program Files\Apache Group\Apache2\htdocs\Client.php on line 79