Crater PHP Framework

fast, lightweight and modular

Errors

Errors? What means errors? We don't have errors :)

How to catch the errors and the throws

You have two choices:

  • With Crater Logger
  • With system error log

For catch with Crater Logger, you need to set true the crater_error_handler setting in your config file.

If you choose to use Crater Logger, errors will be appended in /App/Data/errorlog.html

NOTE: You will need to set write permissions on errorlog.html file

$ sudo chmod 777 /var/www/crater/App/Data/errorlog.html

Error helper

To loop through and display errors without doing it yourself call the display method of the error class:

echo \Core\Error::display('This is an error!');