Fix for PHP Strict Standards issue with PHP 5.4.x

Fix for PHP Strict Standards issue with PHP 5.4.x

During some testing I found an issue with the latest PHP and osTicket. The one coding this puppy is not following php standards from what I understand so you need to disable logging for various errors. So in order to not get the dreaded PHP Strict Standards error in your logs make the following changes.


In the file main.inc.php on line 42 you have

error_reporting(E_ALL ^ E_NOTICE); //Respect whatever is set in php.ini (sysadmin knows better??)

change it to
error_reporting(E_ALL ^ E_NOTICE ^ E_STRICT ^ E_DEPRICATED); //Respect whatever is set in php.ini (sysadmin knows better??)

also below this in the same file on line 155 you have
//Init
$cfg->init();
//Set default timezone...staff will overwrite it.

change it to
//Init
global $cfg;
$cfg->init();
//Set default timezone...staff will overwrite it.

GL! :)

Joomla SEF URLs by Artio