Setting custom error levels in zend framework

How to set custom error levels using the Zend Framework - let's say I want to disable E_NOTICE.

Thanks.

+4
source share
3 answers

If you are using Zend_Application , put the following line in application.ini

 phpsettings.error_reporting = E_ALL & ~E_NOTICE 

You can also use error_reporting() in your bootstrap:

 error_reporting(E_ALL & ~E_NOTICE); 

Error reporting levels described in the PHP manual .

+9
source

In application.ini, this works:

 phpSettings.error_reporting = E_ALL^E_NOTICE 

This will not work:

 phpSettings.error_reporting = "E_ALL^E_NOTICE" 
+2
source

ZF 1.11, application.ini.

It works:

 phpSettings.error_reporting = E_ALL ^ E_NOTICE 

This will not work:

 phpSettings.error_reporting = E_ALL^E_NOTICE phpSettings.error_reporting = "E_ALL^E_NOTICE" 
0
source

All Articles