[wp-trac] [WordPress Trac] #14371: Allow user to specify error reporting level

WordPress Trac wp-trac at lists.automattic.com
Wed Jul 21 03:06:43 UTC 2010

#14371: Allow user to specify error reporting level
 Reporter:  wjm               |       Owner:                 
     Type:  enhancement       |      Status:  new            
 Priority:  normal            |   Milestone:  Awaiting Review
Component:  Warnings/Notices  |     Version:  3.0            
 Severity:  normal            |    Keywords:                 
 I have noticed that there is little control over the error reporting level
 that you can set,

 you can set error_reporting() in your wp-config.php file, but it will be
 overriden in load.php (called by wp-settings.php) by wp_debug_mode();

 this introduces a WP_ERROR_REPORTING constant, that will be checked and if
 set, error reporting will be set to that value.
 either in WP_DEBUG mode or not.

 so for example the, in the wp-config.php of the production installation,
 you use it like this,


 And it will throw no warning messages at all.

 This is also useful in conjunction with WP_DEBUG and WP_DEBUG_LOG, as you
 will be able to specify the error level and also log any errors.

Ticket URL: <http://core.trac.wordpress.org/ticket/14371>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software

More information about the wp-trac mailing list