PHP - Error and Exception Handling
Identify the error in this PHP code snippet:
try {
throw new Exception('Error!');
} catch (Error $e) {
echo 'Caught Error';
}try {
throw new Exception('Error!');
} catch (Error $e) {
echo 'Caught Error';
}Exception object.Error, which does not catch Exception.15+ quiz questions · All difficulty levels · Free
Free Signup - Practice All Questions