CF7 integration causes fatal error

Hi team,
I get this error from a WPML translated contact page on a client site. I get the same on a very different environment. All the rest seems fine, PHP message point to PRO and its form integration.

I tried to insert the form as shortcode, but it does not change the outcome.

PHP message:
PHP Fatal error: Uncaught Error: Call to a member function id() on null in /var/www/html/wp-content/themes/pro/cornerstone/includes/elements/definitions/form-integration.php:140"

The preceding log lines say:

|Jul 27, 2022 10:00:07 PM|Stack trace:"|
|Jul 27, 2022 10:00:07 PM|#0 /var/www/html/wp-content/themes/pro/cornerstone/includes/classes/element/class-element-definition.php(496): x_element_render_form_integration(Array)"|

This is a tourism site, we are in high season and I need to have it All in.

Please visit the Spanish form page and get to Catalan translation via burger top right corner (please click “Català”). That should be triggering the error, will see a very small window displaying partially the page.

Production site. If you need to debug I will offer a staging site.

Thanks!

Ricard

Hello Ricard,

Thanks for writing in! Did you also translated your Contact Form? To better assist you with the issue, we highly recommend that you create a staging site so that we can debug. You can create a secure note in your next reply with the following info:
– Link to your site
– WP login URL
– WP username
– WP password
– WP Administrator Role
– Confirmation that we can access and make changes to your site

To know how to create a secure note, please check this out: How The Forum Works

image

Best Regards.

Hi Rue,
I translated the form to CA and later on tried to create an orphan form (CA) with no language peer.
Same issue.
I have a proofed backup, so I rather give you access to real website, environments are different and I prefer you working on the real thing. Confirmed access and eventual changes.

Please find details in secure note.

Thank you!

Hi Ricard,

I have created a Test page and added a Contact Form 7 using the Form Integration element but didn’t get any error. I have checked that translated page too, but that does not show any error. Please find the test page URL in the secure note. If you are still getting the issue, please let us know the steps to replicate the issue. I would suggest you provide any video that helps us to recognize the problem.

Thanks

Hi @tristup
Sorry guys, I forgot to mention that the error happens if you visit the page while not logged in.
So basically it fails for those who should be contacting :frowning:
I went straight to the test page you created and fatal crash…
I hope this helps you finding the cause.
Thanks!!

Hi Ricard,

I have checked it thoroughly and found that using the Form Integration element causes the issue. I tested with the Text element and added the Contact Form 7 shortcode into it, and it worked perfectly fine. I would like to request you troubleshoot the following common issue to help us to recognize the reason.

  1. Theme Related Issue
  2. Plugin Conflict
  3. Theme Update related issue
  4. Child Theme Related issue
  5. CSS/JS Customization
  6. Disabling Cache
  7. Disabling CDN

If you discover that an issue is coming from a custom code or 3rd party plugin, kindly consult with a developer or contact the plugin author. Please note that we do not provide support for custom codes and 3rd party plugins.
If none of the above help, please copy your live site to a staging server so we could troubleshoot freely without breaking your live site.
And give us access to the secure note including:

– WordPress Site URL & Login URL
– WordPress Admin username/password

To create a secure note, click the key icon underneath any of your posts.

NOTE: Alternatively, you can try the Text or Raw Content element to add the shortcode.

Thanks

This topic was automatically closed 10 days after the last reply. New replies are no longer allowed.