From 07f5140771388c9e0c8a99b0dd2e5d950bdb173b Mon Sep 17 00:00:00 2001 From: Yuchen Pei Date: Thu, 14 Oct 2021 15:16:42 +1100 Subject: moving h-source subdir out. --- admin/Library/ErrorReporting.php | 45 ++++++++++++++++++++++++++++++++++++++++ 1 file changed, 45 insertions(+) create mode 100644 admin/Library/ErrorReporting.php (limited to 'admin/Library/ErrorReporting.php') diff --git a/admin/Library/ErrorReporting.php b/admin/Library/ErrorReporting.php new file mode 100644 index 0000000..18ba519 --- /dev/null +++ b/admin/Library/ErrorReporting.php @@ -0,0 +1,45 @@ +. + +//function to set the error reporting parameters + +function ErrorReporting() { + if (RUNTIME_CONFIGURATION === true) + { + error_reporting(ERROR_REPORTING_DIRECTIVE); + if (DISPLAY_ERRORS === 'On') { + ini_set('display_errors','On'); + } else { + ini_set('display_errors','Off'); + } + + if (ERROR_REPORTING_FILE === true) + { + if (LOG_ERROR_FILE === 'default') + { + ini_set('error_log',ROOT.DS.'Logs/Errors.log'); + } else { + ini_set('error_log',LOG_ERROR_FILE); + } + } + } +} -- cgit v1.2.3