2017 © Pedro Peláez
 

library errorhandler

Quick trigger class for handling all errors and exceptions internally. Defaults to outputting as JSON data

image

primal/errorhandler

Quick trigger class for handling all errors and exceptions internally. Defaults to outputting as JSON data

  • Saturday, December 1, 2012
  • by ChiperSoft
  • Repository
  • 1 Watchers
  • 6 Stars
  • 12 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 2 Forks
  • 0 Open issues
  • 2 Versions
  • 0 % Grown

The README.md

ErrorHandler

Simple to use class for catching all uncaught errors for processing. By default the class outputs the error as JSON, but that behavior can be overridden with a custom callback. Designed to help with error reporting when building APIs, but useful in generic application settings as well. Handles Exceptions, Runtime Errors and Fatal Errors, (*1)

Usage

//defaults to outputting errors as application/json
\Primal\ErrorHandler::Init();

//override with a custom callback to write to a log file
\Primal\ErrorHandler::Init(function ($error) {
    error_log(json_encode($error), 0, '/path/to/error/log');
});

The Versions

01/12 2012

dev-master

9999999-dev http://github.com/PrimalPHP/ErrorHandler

Quick trigger class for handling all errors and exceptions internally. Defaults to outputting as JSON data

  Sources   Download

MIT

The Requires

  • php >=5.3.10

 

json http error exceptions crash

01/12 2012

v1.0.0

1.0.0.0 http://github.com/PrimalPHP/ErrorHandler

Quick trigger class for handling all errors and exceptions internally. Defaults to outputting as JSON data

  Sources   Download

MIT

The Requires

  • php >=5.3.10

 

json http error exceptions crash