Hi folks!
Tell me how should I disable error_reporting in my Yii application correctly?
Should I use
error_reporting(0);
in the index.php file or is not correct?
Thanks.
Hi folks!
Tell me how should I disable error_reporting in my Yii application correctly?
Should I use
error_reporting(0);
in the index.php file or is not correct?
Thanks.
Hi,
in config/main.php you can disable this here
...
'errorHandler'=>array(
// use 'site/error' action to display errors
'errorAction'=>'site/error',
),
....
Also you can turn debug mode off in
index.php
// remove the following lines when in production mode
// defined('YII_DEBUG') or define('YII_DEBUG',true);
// specify how many levels of call stack should be shown in each log message
// defined('YII_TRACE_LEVEL') or define('YII_TRACE_LEVEL',3);