Ahlahn
05-31-2011, 02:05 AM
Lets say I have the following code
$test = preg_match_all($regular_expression, $string, $blah);
If my regular expression is incorrect, it will display a "missing delimiter" error or a "out of range" error. How do I use exceptions in PHP so that I can catch the exception and display a unique message without seeing the error message?
$test = preg_match_all($regular_expression, $string, $blah);
If my regular expression is incorrect, it will display a "missing delimiter" error or a "out of range" error. How do I use exceptions in PHP so that I can catch the exception and display a unique message without seeing the error message?