Last active
May 24, 2023 20:23
-
-
Save allysonsouza/8a4d09d4366bcf475bf62fae97cd22b4 to your computer and use it in GitHub Desktop.
Error Reporting Level for WordPress
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* Plugin Name: Error Reporting Level | |
* Description: Sets the error reporting level for your WordPress install. View more on: https://www.php.net/manual/en/errorfunc.configuration.php#ini.error-reporting | |
* Plugin URI: | |
* Version: | |
* Author: Allyson | |
* Author URI: https://allysonsouza.com.br | |
* License: GPL2 | |
* License URI: https://www.gnu.org/licenses/gpl-2.0.html | |
* cURL install as mu-plugin: curl -O https://gist.githubusercontent.com/allysonsouza/8a4d09d4366bcf475bf62fae97cd22b4/raw/1a3eec6367d9f0fc852691f0283c12aa18319ebf/error-reporting-level.php && mv error-reporting-level.php ./wp-content/plugins/mu-plugins/ | |
*/ | |
*/ | |
// Disable Notices, Strict and Deprecated | |
error_reporting(E_ALL & ~E_NOTICE & ~E_STRICT & ~E_DEPRECATED); | |
// Disable only Deprecated | |
// error_reporting(E_ALL & ~E_DEPRECATE); | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Install it as a
must-use-plugin
, in/mu-plugins
directory and set theerror_reporting()
function according to what level of reporting do you need for your WordPress install.