diff --git a/html/css/styles.css b/html/css/styles.css index 0cfcf6328..df4e0da6a 100644 --- a/html/css/styles.css +++ b/html/css/styles.css @@ -1628,3 +1628,6 @@ tr.search:nth-child(odd) { font-size: 2.5em; } +.navbar-debug { + min-height: 25px; +} diff --git a/html/includes/print-debug.php b/html/includes/print-debug.php new file mode 100644 index 000000000..5c23a3536 --- /dev/null +++ b/html/includes/print-debug.php @@ -0,0 +1,89 @@ + + +
+ + diff --git a/html/index.php b/html/index.php index d0448a7e4..037843a35 100755 --- a/html/index.php +++ b/html/index.php @@ -47,6 +47,7 @@ if (strpos($_SERVER['PATH_INFO'], "debug")) ini_set('display_startup_errors', 1); ini_set('log_errors', 1); ini_set('error_reporting', E_ALL); + set_error_handler('logErrors'); } else { $debug = FALSE; ini_set('display_errors', 0); @@ -55,6 +56,11 @@ if (strpos($_SERVER['PATH_INFO'], "debug")) ini_set('error_reporting', 0); } +function logErrors($errno, $errstr, $errfile, $errline) { + global $php_debug; + $php_debug[] = array('errno' => $errno, 'errstr' => $errstr, 'errfile' => $errfile, 'errline' => $errline); +} + foreach ($_GET as $key=>$get_var) { if (strstr($key, "opt")) @@ -330,6 +336,13 @@ toastr.options.extendedTimeOut = 20; echo(""); } +if (is_array($sql_debug) && is_array($php_debug)) { + + include_once "includes/print-debug.php"; + +} + ?> +