Code: Select all
// Warning
throw new Exception($message, 1, __CLASS__);
// Fatal
throw new Exception($message, 2, __CLASS__);Code: Select all
try {
// Script
} catch (Exception $e) {
// I will be doing more with this based on warning or fatal, but for now ...
exit($e->getCode());
}Code: Select all
class Warning_Exception extends Exception { }
class Fatal_Exception extends Exception { }