• Pls I need help fixing the error below showing on my wordpress website. safa.com.ng

    Fatal error: Cannot redeclare global_terms_enabled() (previously declared in /home/safa22/public_html/wp-includes/functions.php:6224) in /home/safa22/public_html/wp-includes/deprecated.php on line 4509

    Fatal error: Uncaught Error: Call to a member function set() on null in /home/safa22/public_html/wp-includes/l10n.php:784 Stack trace: #0 /home/safa22/public_html/wp-includes/l10n.php(872): load_textdomain(‘default’, ‘/home/safa22/pu…’, ‘en_GB’) #1 /home/safa22/public_html/wp-includes/class-wp-fatal-error-handler.php(46): load_default_textdomain() #2 [internal function]: WP_Fatal_Error_Handler->handle() #3 {main} thrown in /home/safa22/public_html/wp-includes/l10n.php on line 784

    The page I need help with: [log in to see the link]

Viewing 2 replies - 1 through 2 (of 2 total)
  • Hi, go into the file /wp-includes/deprecated.php to line 4509

    Then replace these lines 4509 to 4513 from this:

    function global_terms_enabled() {
             _deprecated_function( __FUNCTION__, '6.1.0');
             return false;
    }

    To this:

    if(!function_exists('global_terms_enabled')){
        function global_terms_enabled() {
             _deprecated_function( __FUNCTION__, '6.1.0');
             return false;
        }
    }

    This will check if the function already exists and only if not declare it, thus eliminating the redaclare error

    • This reply was modified 1 year, 5 months ago by !Benni.
    Thread Starter bamideleayo

    (@bamideleayo)

    Please it’s still reporting this error;

    
    

    Deprecated: File class.wp-dependencies.php is deprecated since version 6.1.0! Use wp-includes/class-wp-dependencies.php instead. in /home/safa22/public_html/wp-includes/functions.php on line 5571

    Warning: require_once(/home/safa22/public_html/wp-includes/class-wp-dependencies.php): failed to open stream: No such file or directory in /home/safa22/public_html/wp-includes/class.wp-dependencies.php on line 14

    Fatal error: require_once(): Failed opening required ‘/home/safa22/public_html/wp-includes/class-wp-dependencies.php’ (include_path=’.:/opt/cpanel/ea-php74/root/usr/share/pear’) in /home/safa22/public_html/wp-includes/class.wp-dependencies.php on line 14

    Fatal error: Uncaught Error: Call to a member function set() on null in /home/safa22/public_html/wp-includes/l10n.php:784 Stack trace: #0 /home/safa22/public_html/wp-includes/l10n.php(872): load_textdomain(‘default’, ‘/home/safa22/pu…’, ‘en_GB’) #1 /home/safa22/public_html/wp-includes/class-wp-fatal-error-handler.php(46): load_default_textdomain() #2 [internal function]: WP_Fatal_Error_Handler->handle() #3 {main} thrown in /home/safa22/public_html/wp-includes/l10n.php on line 784`
    `

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Fatal error: Cannot redeclare global_terms_enabled()’ is closed to new replies.