|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2007-09-27 09:47 UTC] jani@php.net
[2007-09-27 09:48 UTC] jani@php.net
[2007-10-12 10:15 UTC] tjerk dot meesters at muvee dot com
[2007-11-01 12:27 UTC] dmitry@php.net
[2007-11-01 14:12 UTC] dmitry@php.net
|
|||||||||||||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Tue Oct 28 09:00:01 2025 UTC |
Description: ------------ Failure to load a WSDL file using the SoapClient class causes more than just an exception. The error is also caught by the error handler and a 500 status code is sent back. This error is classified as a PHP Fatal error and can't be caught by any custom error handlers. This error shouldn't be triggered at all, that's what we have exceptions for ;-) Reproduce code: --------------- <?php try { $s = new SoapClient('http://localhost/invalid_wsdl'); } catch (Exception $e) { echo $e->getMessage(); } ?> Expected result: ---------------- SOAP-ERROR: Parsing WSDL: Couldn't load from 'http://localhost/invalid_wsdl' Actual result: -------------- [HTTP/1.x 500 Internal Server Error] PHP Fatal error: SOAP-ERROR: Parsing WSDL: Couldn't load from 'http://localhost/invalid_wsdl' in /var/www/html/test.php on line 4 SOAP-ERROR: Parsing WSDL: Couldn't load from 'http://localhost/invalid_wsdl'