Skip Navigation

[Resolved] some of my cred ajax forms giving submission error

This support ticket is created 6 years, 11 months ago. There's a good chance that you are reading advice that it now obsolete.

This is the technical support forum for Toolset - a suite of plugins for developing WordPress sites without writing PHP.

Everyone can read this forum, but only Toolset clients can post in it. Toolset support works 6 days per week, 19 hours per day.

No supporters are available to work today on Toolset forum. Feel free to create tickets and we will handle it as soon as we are online. Thank you for your understanding.

Sun Mon Tue Wed Thu Fri Sat
- 10:00 – 13:00 10:00 – 13:00 10:00 – 13:00 10:00 – 13:00 10:00 – 13:00 -
- 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 -

Supporter timezone: Asia/Kolkata (GMT+05:30)

This topic contains 5 replies, has 2 voices.

Last updated by Minesh 6 years, 11 months ago.

Assisted by: Minesh.

Author
Posts
#597562

I am trying to:
I am using cred ajax. its seems to save on all forms but on some it gives and 500 (Internal Server Error) and throws up a alert.

As I said is works fine on some forms but throws up this message on other forms

Link to a page where the issue can be seen:

I expected to see:

Instead, I got:

#597620

Minesh
Supporter

Languages: English (English )

Timezone: Asia/Kolkata (GMT+05:30)

Hello. Thank you for contacting the Toolset support.

Well - this is strange that it works for few forms and not working for other forms.

Is your CRED form using any CRED API? For instance, a cred_save_data hook or a cred_mail_headers hook?
- I would like to see if your WordPress installation is registering any errors. You can see how to enable debug logging here:
https://toolset.com/documentation/user-guides/debugging-toolset/

Go in your wp-config.php file and look for define(‘WP_DEBUG’, false);. Change it to:

define('WP_DEBUG', true);

Then add these lines, just before it says 'stop editing here':

ini_set('log_errors',TRUE);
ini_set('error_reporting', E_ALL);
ini_set('error_log', dirname(__FILE__) . '/error_log.txt');

Then try to submit the CRED form where you encounter the errors and check your server log - do you see anything?

If any errors are generated, this will create an error_log.txt file in your site's root directory. Please share error_log errors with me.

#597668

Hi,
when I add in those lines the error stops. Please advise

#597932

Minesh
Supporter

Languages: English (English )

Timezone: Asia/Kolkata (GMT+05:30)

Well - there is nothing related to the code lines I shared with you that should fix the AJAX issue. This looks like something from your server not working consistently.

#598008

Hi,
I dont agree with that it is to do with the server. As I stated already some forms with ajax submission have been working without error. I need this resolved urgently as it is a major issue for users.
Please help.

#598342

Minesh
Supporter

Languages: English (English )

Timezone: Asia/Kolkata (GMT+05:30)

Well - you said with following reply that by adding the code lines I shared with you resolve the issue:
=> https://toolset.com/forums/topic/some-of-my-cred-ajax-forms-giving-submission-error/#post-597668

The fact is that, the code lines are related to activating WP_DEBUG and error log - I wonder how it fix your issue.

Did you follow the guidelines I gave with the following reply?
https://toolset.com/forums/topic/some-of-my-cred-ajax-forms-giving-submission-error/#post-597620
If yes:
Did you see anything in error log?