ID: 31696 Updated by: [EMAIL PROTECTED] Reported By: gredata at yahoo dot com -Status: Open +Status: Bogus Bug Type: *General Issues Operating System: linux PHP Version: 4.3.10 New Comment:
Sorry, but your problem does not imply a bug in PHP itself. For a list of more appropriate places to ask for help using PHP, please visit http://www.php.net/support.php as this bug system is not the appropriate forum for asking support questions. Thank you for your interest in PHP. Where did you read that PHP 4.3.10 supports exceptions? Exceptions are supported starting from 5.0. Previous Comments: ------------------------------------------------------------------------ [2005-01-25 23:32:52] gredata at yahoo dot com Description: ------------ Hello I've installed apache2 and php-4.3.10 I copy from on-line documentation one part about exceptions just like is it and it is not working. Look below. Why you putted something in docs that is not working???? Reproduce code: --------------- <?php try { $error = 'Always throw this error'; throw new Exception($error); // Code following an exception is not executed. echo 'Never executed'; } catch (Exception $e) { echo 'Caught exception: ', $e->getMessage(), "\n"; } // Continue execution echo 'Hello World'; ?> Expected result: ---------------- Caught exception: Always throw this error Hello World Actual result: -------------- Parse error: parse error, unexpected '{' in /var/www/localhost/htdocs/testing/tt.php on line 2 ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/?id=31696&edit=1