• Resolved zeno001

    (@zeno001)


    I got the following error trying to edit the Posts page:

    “There has been a critical error on your website. Please check your site admin email inbox for instructions.”

    I have checked another site and get the same error. I’m using templates created using Artisteer on both.

    It was accidental that I clicked on that page – it should never need to be edited – and it doesn’t seem to affect anything else and the site appears to be fully functional, but is still worrying.

    The email I got from the site included the following:

    WordPress version 5.3.2
    Current theme: Draft0_15 (version 1.0)
    Current plugin: (version )
    PHP version 7.2.26

    Error Details
    =============
    An error of type E_ERROR was caused in line 252 of the file /var/www/vhosts/medico-legalsociety.org.uk/httpdocs/wp-content/themes/Draft0_15/functions.php. Error message: Uncaught ArgumentCountError: Too few arguments to function theme_update_title(), 1 passed in /var/www/vhosts/medico-legalsociety.org.uk/httpdocs/wp-includes/class-wp-hook.php on line 288 and exactly 2 expected in /var/www/vhosts/medico-legalsociety.org.uk/httpdocs/wp-content/themes/Draft0_15/functions.php:252
    Stack trace:
    #0 /var/www/vhosts/medico-legalsociety.org.uk/httpdocs/wp-includes/class-wp-hook.php(288): theme_update_title(‘News | The Medi…’)
    #1 /var/www/vhosts/medico-legalsociety.org.uk/httpdocs/wp-includes/plugin.php(206): WP_Hook->apply_filters(‘News | The Medi…’, Array)
    #2 /var/www/vhosts/medico-legalsociety.org.uk/httpdocs/wp-content/plugins/all-in-one-seo-pack/aioseop_class.php(1859): apply_filters(‘single_post_tit…’, ‘News | The Medi…’)
    #3 /var/www/vhosts/medico-legalsociety.org.uk/httpdocs/wp-content/plugins/all-in-one-seo-pack/aioseop_class.php(1715): All_in_One_SEO_Pack->get_aioseop_title(Object(WP_Post))
    #4 /var/www/vhosts/medico-legalsociety.org.uk/httpdocs/wp-content/plugins/all-in

    The root of the error seems to be in AIOSEO and/or the template. If I disable AIOSEO and try to edit the posts page it all appears as it should without that error. If I revert to the twenty-twenty template, it all works as well.

    My template is created using Artisteer so it could be a problem with interaction with that. I know Artisteer is essentially not supported now but I recreated the template zip file so that any recent updates were included but I still get the error with AIOSEO activated.

    Any idea what’s causing this? As I said, it doesn’t seem to affect anything else and may just be limited to trying to edit the Posts page but cannot be certain, so it would be good to get to the bottom of it.

    AIOSEO Version 3.3.4
    WordPress 5.3.2
    PHP 7.2.26
    Database 5.5.64-MariaDB

Viewing 3 replies - 1 through 3 (of 3 total)
  • Plugin Support Steve M

    (@wpsmort)

    @zeno001 That error is coming from line 252 of the functions.php file in your Draft0_15 theme.

    Thread Starter zeno001

    (@zeno001)

    Thanks! I’ll chase it up with Artisteer.

    Thread Starter zeno001

    (@zeno001)

    I’m back here again…

    Artisteer are telling me the error originates from the AIOSEO plugin. The error starts here:

    An error of type E_ERROR was caused in line 252 of the file /var/www/vhosts/medico-legalsociety.org.uk/httpdocs/wp-content/themes/Draft0_15/functions.php.
    Error message: Uncaught ArgumentCountError: Too few arguments to function theme_update_title(), 1 passed in /var/www/vhosts/medico-legalsociety.org.uk/httpdocs/wp-includes/class-wp-hook.php on line 288 and exactly 2 expected in /var/www/vhosts/medico-legalsociety.org.uk/httpdocs/wp-content/themes/Draft0_15/functions.php:252

    This function definition in the theme functions.php:

    function theme_update_title($title, $post)

    …requires two parameters. The call comes from the core WordPress function in class-wp-hook.php and that is only passing one parameter.

    However, although this is a core WordPress file, I understand it’s the plugin calling the WordPress hook with the wrong number of parameters – as the stack trace shows.

    If I disable AIOSEO, I don’t get the error, so it all seems to point to the plugin.

    Can you confirm this?

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Critical error editing Posts page’ is closed to new replies.