How to hide PHP Warnings And Notices in WordPress
PHP warnings and notices can be generated due to WordPress and PHP conflicts. But you don’t have to worry as they can be fixed in newer versions. However, there is a simple hack for this.
How To Hide Them?
If you have set
false in your
wp-config.php file that will fix the issue.
However, if it doesn’t hide errors simply paste following code after
define('WP_DEBUG', false); in your
with this code:
ini_set('display_errors','Off'); ini_set('error_reporting', E_ALL ); define('WP_DEBUG', false); define('WP_DEBUG_DISPLAY', false);
You will see the magic and no more errors will be there.