Error that switches theme to default
-
Hello! I installed Neve on my site but encountered a problem: every 60 minutes WordPress automatically deactivates the theme and replaces it with the default one. If I try removing the following code:
function _neve_bootstrap_errors() { global $_neve_bootstrap_errors; printf( '<div class="notice notice-error"><p>%1$s</p></div>', $_neve_bootstrap_errors->get_error_message() ); // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped } if ( $_neve_bootstrap_errors->has_errors() ) { /** * Add notice for PHP upgrade. */ add_filter( 'template_include', '__return_null', 99 ); switch_theme( WP_DEFAULT_THEME ); unset( $_GET['activated'] ); // phpcs:ignore WordPress.Security.NonceVerification.Recommended add_action( 'admin_notices', '_neve_bootstrap_errors' ); return; }
from functions.php, I get the following error message in the WordPress error log:
PHP Fatal error: Cannot use isset() on the result of an expression (you can use "null !== expression" instead) in /home/silvinab/public_html/wp-content/themes/neve/globals/utilities.php on line 554
Can you please advise how to fix this?
If you need information on the PHP install and setup, it’s available here.
The page I need help with: [log in to see the link]
Viewing 14 replies - 1 through 14 (of 14 total)
Viewing 14 replies - 1 through 14 (of 14 total)
- The topic ‘Error that switches theme to default’ is closed to new replies.