Created
May 31, 2014 02:34
-
-
Save leviwheatcroft/8029f587f62a9e81b150 to your computer and use it in GitHub Desktop.
Debug like a pro with Kint! It seems odd to me that Kint doesn't do this automagically. Maybe it's also odd that I've been using Kint for months and only just figured out that this is what I should be doing.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
define('__ROOT__',dirname(__FILE__)); | |
require_once __ROOT__ . '/lib/kint/Kint.class.php'; | |
function kint_error_handler($errno, $errstr, $errfile, $errline, $errcontext) { | |
Kint::dump(func_get_args()); | |
Kint::trace(); | |
die(); | |
} | |
set_error_handler('kint_error_handler'); | |
trigger_error('pfft..'); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment