• Resolved philipbutlerfreelance

    (@philipbutlerfreelance)


    Hi,

    I’ve just done updates my the website, and now getting the dreaded ‘There has been a critical error on this website’ message, disabling the Post My CF7 Form plugin allows the page to load.

    I’ve had a look at the server log and I’m getting the following:

    PHP Fatal error: Uncaught Error: Call to undefined function c2p_get_form_key() in /var/www/vhosts/xxxxxxx.org/httpdocs/wp-content/plugins/post-my-contact-form-7/public/class-cf7-2-post-public.php:177

    WordPress v 6.3.2
    CF7 Smart Grid Design Extension v4.15.4
    Conditional Fields PRO v2.1.2
    Contact Form 7 v5.5.6
    Post My CF7 Form v 6.0.1
    PHP v7.3.25

    Note that on the live site I’ve restored a backup so the error no longer exists. Thanks for any support you can provide to get this resolved. x

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

Viewing 15 replies - 1 through 15 (of 15 total)
  • Plugin Author Aurovrata Venet

    (@aurovrata)

    That a little odd, can you check your installation plugin folder and make sure the function is being declared on line 505 of the following file,

    wp-content/plugins/post-my-contact-form-7/assets/cf7-admin-table/admin/class-cf7-wp-post-table.php

    The Smart Grid and this plugin both share a common library, however in v6.0.1 I have modified the library class declaration so make sure it no longer picks up the older (not upgraded definition that resides in the smart grid plugin package).

    Plugin Author Aurovrata Venet

    (@aurovrata)

    ok, my bad, I realised class names are case-insensitive in PHP, and renamed the library class name causing the issue. This is fixed in v6.0.2.

    Thread Starter philipbutlerfreelance

    (@philipbutlerfreelance)

    Hi,

    I’ve just installed a working backup (pre plugin update) of the site onto a PHP 8.x hosting package to rule out php.
    Bizarrely it is now CF7 Smart Grid Design Extension that seems to trigger the critical error.

    [ Deleted ]

    Plugin Author Aurovrata Venet

    (@aurovrata)

    odd indeed. Thanks for the report. This looks like a php 8 issue., I am running php7.4 on my dev server and not seeing this. I will run a test on my server and get back to you on this.

    Moderator Jan Dembowski

    (@jdembowski)

    Forum Moderator and Brute Squad

    @philipbutlerfreelance

    Please do not post large code or responses like that here, it doesn’t work after ~10 lines or so.

    If you need share that data please use https://gist.github.com/ or https://pastebin.com/ or the like instead and post the link to that paste.

    Thread Starter philipbutlerfreelance

    (@philipbutlerfreelance)

    Not sure if I’ve done this right but here are the error logs https://gist.github.com/butlerps/60af1b4384b683d111a641d865096ac4

    Thread Starter philipbutlerfreelance

    (@philipbutlerfreelance)

    Trying to help you as much as I can. I’ve just installed a working version of the site onto my localhost running php 7.4
    Tried updating Post My CF7 Form to 6.02 first before doing the Smart Grid plugin. It triggered fatal errors on the front end, I’ve updated the Gist with the new errors from my localhost

    https://gist.github.com/butlerps/60af1b4384b683d111a641d865096ac4

    hope it helps.

    Thread Starter philipbutlerfreelance

    (@philipbutlerfreelance)

    Modified wp-content/plugins/post-my-contact-form-7/admin/class-cf7-2-post-admin.php line 90
    OLD
    require_once plugin_dir_path( dirname( FILE ) ) . ‘assets/cf7-admin-table/admin/class-cf7-wp-post-table.php’;
    NEW
    require_once plugin_dir_path( dirname( FILE ) ) . ‘assets/cf7-admin-table/admin/class-cf7sg-wp-post-table.php’;

    Now getting a new set of errors shown on the Gist page

    Thread Starter philipbutlerfreelance

    (@philipbutlerfreelance)

    Just tried updating the Smart Grid plugin and the front end is now working. Furthermore I updated php to v8.0 and the site is still working.

    I’ve just modified Modified wp-content/plugins/post-my-contact-form-7/admin/class-cf7-2-post-admin.php line 90 to include the correct file name on the live server running php v8.2.10 and wordpress v6.3.2 and everything is running okay. (I think).

    Thx – yes, there’s a typo. the php is missing a “sg”. It’s working again.

    Plugin Author Aurovrata Venet

    (@aurovrata)

    v6.0.3 fixes the typo

    Plugin Author Aurovrata Venet

    (@aurovrata)

    @philipbutlerfreelance wrt

    I’ve just installed a working backup (pre plugin update) of the site onto a PHP 8.x hosting package to rule out php.
    Bizarrely it is now CF7 Smart Grid Design Extension that seems to trigger the critical error.

    I just got a php8.2 server setup on which I will run some tests tomorrow and get back to you on this.

    Thread Starter philipbutlerfreelance

    (@philipbutlerfreelance)

    Hi,

    quick update, my last lot of errors may have been due to a caching problem; cache cleared and the plugins don’t cause any errors. It looks like it was just the one file name problem. Thanks for all your support…. a donation is on its way. 🙂

    Plugin Author Aurovrata Venet

    (@aurovrata)

    thank you for your help and patience Philip.

    a donation is on its way. 🙂

    ooh, nice! Will drink a beer to your health 🙂

    PS: Currently developing the CF7 Smart Grid v5.0 which is a big rewrite of the plugin. Its now in beta stable mode, with v5.0.0beta11 released for testing. If you have some time to spare, I would very much appreciate some help in testing it out.

    Thread Starter philipbutlerfreelance

    (@philipbutlerfreelance)

    PS: Currently developing the CF7 Smart Grid v5.0 which is a big rewrite of the plugin. Its now in beta stable mode, with v5.0.0beta11 released for testing. If you have some time to spare, I would very much appreciate some help in testing it out.

    Absolutely! As it happens I need to re-design a ‘check availability’ form on one of my sites, the plan was to turn it into a multi-step form (not quite sure how to yet). I’ll install your v50.0beta11 onto my localhost for testing.

Viewing 15 replies - 1 through 15 (of 15 total)

The topic ‘There has been a critical error on this website with v6.0.1 and WP v6.3.2’ is closed to new replies.