aboutsummaryrefslogtreecommitdiff
path: root/h-source/Library/ErrorReporting.php
blob: bc541bc21e4fdfe2d3bc24b22fe18cdb843ba7e3 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
<?php

//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);
			}
		}
	}
}