Display PHP Start-up Errors/Warnings. Props Denis-de-Bernardy. Fixes #12395.

git-svn-id: http://svn.automattic.com/wordpress/trunk@13499 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
dd32 2010-02-28 12:19:09 +00:00
parent 7b2c083769
commit b90b27a6d6
4 changed files with 8 additions and 8 deletions

View File

@ -149,9 +149,9 @@ if ( !empty($action) ) {
if ( ! WP_DEBUG ) {
if ( defined('E_RECOVERABLE_ERROR') )
error_reporting(E_ERROR | E_WARNING | E_PARSE | E_USER_ERROR | E_USER_WARNING | E_RECOVERABLE_ERROR);
error_reporting(E_CORE_ERROR | E_CORE_WARNING | E_COMPILE_ERROR | E_ERROR | E_WARNING | E_PARSE | E_USER_ERROR | E_USER_WARNING | E_RECOVERABLE_ERROR);
else
error_reporting(E_ERROR | E_WARNING | E_PARSE | E_USER_ERROR | E_USER_WARNING);
error_reporting(E_CORE_ERROR | E_CORE_WARNING | E_COMPILE_ERROR | E_ERROR | E_WARNING | E_PARSE | E_USER_ERROR | E_USER_WARNING);
}
@ini_set('display_errors', true); //Ensure that Fatal errors are displayed.

View File

@ -54,9 +54,9 @@ if ( isset($_GET['action']) ) {
echo '<p>' . __('Plugin failed to reactivate due to a fatal error.') . '</p>';
if ( defined('E_RECOVERABLE_ERROR') )
error_reporting(E_ERROR | E_WARNING | E_PARSE | E_USER_ERROR | E_USER_WARNING | E_RECOVERABLE_ERROR);
error_reporting(E_CORE_ERROR | E_CORE_WARNING | E_COMPILE_ERROR | E_ERROR | E_WARNING | E_PARSE | E_USER_ERROR | E_USER_WARNING | E_RECOVERABLE_ERROR);
else
error_reporting(E_ERROR | E_WARNING | E_PARSE | E_USER_ERROR | E_USER_WARNING);
error_reporting(E_CORE_ERROR | E_CORE_WARNING | E_COMPILE_ERROR | E_ERROR | E_WARNING | E_PARSE | E_USER_ERROR | E_USER_WARNING);
@ini_set('display_errors', true); //Ensure that Fatal errors are displayed.
include(WP_PLUGIN_DIR . '/' . $plugin);

View File

@ -262,9 +262,9 @@ function wp_debug_mode() {
}
} else {
if ( defined( 'E_RECOVERABLE_ERROR' ) )
error_reporting( E_ERROR | E_WARNING | E_PARSE | E_USER_ERROR | E_USER_WARNING | E_RECOVERABLE_ERROR );
error_reporting( E_CORE_ERROR | E_CORE_WARNING | E_COMPILE_ERROR | E_ERROR | E_WARNING | E_PARSE | E_USER_ERROR | E_USER_WARNING | E_RECOVERABLE_ERROR );
else
error_reporting( E_ERROR | E_WARNING | E_PARSE | E_USER_ERROR | E_USER_WARNING );
error_reporting( E_CORE_ERROR | E_CORE_WARNING | E_COMPILE_ERROR | E_ERROR | E_WARNING | E_PARSE | E_USER_ERROR | E_USER_WARNING );
}
}

View File

@ -20,9 +20,9 @@
define( 'ABSPATH', dirname(__FILE__) . '/' );
if ( defined('E_RECOVERABLE_ERROR') )
error_reporting(E_ERROR | E_WARNING | E_PARSE | E_USER_ERROR | E_USER_WARNING | E_RECOVERABLE_ERROR);
error_reporting(E_CORE_ERROR | E_CORE_WARNING | E_COMPILE_ERROR | E_ERROR | E_WARNING | E_PARSE | E_USER_ERROR | E_USER_WARNING | E_RECOVERABLE_ERROR);
else
error_reporting(E_ERROR | E_WARNING | E_PARSE | E_USER_ERROR | E_USER_WARNING);
error_reporting(E_CORE_ERROR | E_CORE_WARNING | E_COMPILE_ERROR | E_ERROR | E_WARNING | E_PARSE | E_USER_ERROR | E_USER_WARNING);
if ( file_exists( ABSPATH . 'wp-config.php') ) {