Home > CMS Tutorial > WordPress > Disable WordPress fatal error (WSOD) handling

Disable WordPress fatal error (WSOD) handling

藏色散人
Release: 2019-11-07 11:39:29
forward
2878 people have browsed it

The following column WordPress Tutorial will introduce how to disable WordPress fatal error (WSOD) processing. I hope it will be helpful to friends in need!

Disable WordPress fatal error (WSOD) handling

WordPress 5.2 has a new built-in feature that automatically sends an email to notify the website administrator when an error is detected in a plugin or theme, even if the backend is completely inaccessible. (such as when a so-called "white screen of death" occurs), the administrator still has the opportunity to log in and take action on the problem.

If you want to disable this feature, you can use the following method:

Method 1

Open the WordPress configuration file wp-config.php and add:

define( 'WP_DISABLE_FATAL_ERROR_HANDLER', true );
Copy after login

Method 2

Add the following code to the current theme function template functions.php:

add_filter( 'wp_fatal_error_handler_enabled', '__return_false' );
Copy after login

The above is the detailed content of Disable WordPress fatal error (WSOD) handling. For more information, please follow other related articles on the PHP Chinese website!

Related labels:
source:zmingcx.com
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template