From 13bf3b65078f69d80730f46660929ae9108a585d Mon Sep 17 00:00:00 2001 From: Benjamin Renard Date: Tue, 12 Mar 2019 11:36:21 +0100 Subject: [PATCH] Log all errors on developpement instance and with magic URL parameter LSdebug --- public_html/core.php | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/public_html/core.php b/public_html/core.php index 4a9beb09..847f4cb5 100644 --- a/public_html/core.php +++ b/public_html/core.php @@ -24,7 +24,10 @@ ini_set( 'magic_quotes_gpc', 'off' ); ini_set( 'magic_quotes_sybase', 'off' ); ini_set( 'magic_quotes_runtime', 'off' ); -error_reporting(E_ALL & ~E_NOTICE & ~E_STRICT & ~E_DEPRECATED); +if (isset($_REQUEST['LSdebug']) || preg_match('/^127\.[0-9]+\.[0-9]+\.[0-9]+$/', $_SERVER['HTTP_HOST'])) + error_reporting(E_ALL); +else + error_reporting(E_ALL & ~E_NOTICE & ~E_STRICT & ~E_DEPRECATED); // Définitions des dossiers d'inclusions define('LS_CONF_DIR','conf/');