There is no any line related the error but it says critical error

My website says critical error on website after add my custom code but there is no any line related my custom code in log file.There are only 2 repater lines and they are standard for my website, not big problems.

also Wordpress doesn't show error message on browser except critical error....

how can I detect the code problem?

define( 'WP_DEBUG', true );
define( 'WP_DEBUG_LOG', true );
define( 'SAVEQUERIES', true );
define( 'SCRIPT_DEBUG', true );
define( 'WP_DEBUG_DISPLAY', true );
error_reporting(E_ALL);
ini_set('display_errors', 1);

Topic wp-debug debug Wordpress

Category Web


You could try the following wp-config.php setup - note WP writes to the file wp-content/debug.log - this config also stops any errors from being rendered to the browser.

Note that setting the constant WP_DISABLE_FATAL_ERROR_HANDLER to true enables you to disabled the default WP error screen.

// Disable display of errors and warnings 
@ini_set('display_errors',0);

define( 'WP_DEBUG_LOG', true );

define( 'WP_DEBUG', true );

define( 'WP_DEBUG_DISPLAY', false );

define( 'SCRIPT_DEBUG', false );

// disable WP fail-safe screen ##
define( 'WP_DISABLE_FATAL_ERROR_HANDLER', true );

About

Geeks Mental is a community that publishes articles and tutorials about Web, Android, Data Science, new techniques and Linux security.