hide php errors – Nexyta https://www.nexyta.com Your Next, We Care Fri, 18 Nov 2016 02:41:09 +0000 en-US hourly 1 https://www.nexyta.com/wp-content/uploads/2017/12/Nexyta_favicon.png hide php errors – Nexyta https://www.nexyta.com 32 32 How to hide PHP errors in WordPress https://www.nexyta.com/hide-php-errors-wordpress/ https://www.nexyta.com/hide-php-errors-wordpress/#respond Wed, 16 Nov 2016 14:36:58 +0000 http://www.nexyta.com/?p=2062 PHP errors notice display in WordPress is very common issue. Sometimes when you create your website with WordPress, you may not want to display php errors. A WordPress web developers always try to fix these kind of errors. If you use any premium theme, you may not worry about it because developers always try to fix these kind of issues. Many of these errors comes after upgrading New WordPress version.

Don’t worry, you can hide PHP errors message in WordPress by editing WordPress configuration(wp-config.php) file.

WP_DEBUG:  Generally WP_DEBUG used for developers to trigger the “debug” mode. If you set WP_DEBUG to false in your wp-config.php file, may be your problem will be solved.

Sometimes above method does not work. That can be happen most of times on cheap share hosts force displaying PHP errors. Don’t worry follow below method.

Replace WP_DEBUG:  If you are failed on above method, just replace following line from wp-config.php file.

define('WP_DEBUG', false);

with this

ini_set('log_errors','On');
ini_set('display_errors','Off');
ini_set('error_reporting', E_ALL );
define('WP_DEBUG', false);
define('WP_DEBUG_LOG', true);
define('WP_DEBUG_DISPLAY', false);

That’s all. We hope this article helped you learn how to hide PHP errors in WordPress.

]]>
https://www.nexyta.com/hide-php-errors-wordpress/feed/ 0