WPIntell

Source evidence

Captcha mismatch after failed submission

reCAPTCHA for Ninja Forms · support · 2016-05-26T02:36:00+00:00

complaintsentiment
highseverity
1.0relevance
3replies
Evidence linked to opportunitycommercial context

Proof Health

Open evidence

Commercial opportunities need traceable source links before they are treated as build-worthy.

4 / 34 rows with source links

11.8% of this page's analysis has direct source links.

0 build-decision rows missing links

0 rows here require auditable proof before promotion.

30 rows with no attached evidence

0 rows have source counts but still need direct links.

Conversation

support
websource unresolved
Scenario: You fill out the form, get the tick with recaptcha, but miss a required field and get the prompt. You complete the required field and try to resubmit. Form now fails with “Captcha mismatch, Please try again.” – except there’s no option to recheck the box since it’s still checked. Shouldn’t the recaptcha reset after a failed submission? Ninja Forms Version 2.9.45 Ninja Forms reCAPTCHA Version 1.2.5 https://wordpress.org/plugins/ninja-forms-recaptcha-field/ I have exactly the same problem. Anyone a solution? thanks! This is my solution to the problem: (function($) { $(document).ready(function() { jQuery(".ninja-forms-form").on('submitResponse.resetCaptcha', function(e, formData, jqForm, options){ if (grecaptcha && grecaptcha.getResponse()) { grecaptcha.reset(); } }); }); })(jQuery); It resets the captcha state (if it was activated) after submitResponse event. This is a solution for ajax powered form. (function($) { $(document).ready(function() { jQuery(".ninja-forms-form").on('submitResponse.resetCaptcha', function(e, formData, jqForm, options){ if (typeof grecaptcha !== 'undefined') { // add error manually if captcha isn't solved if (!grecaptcha.getResponse()) { jQuery("#ninja_forms_field_8_error").prop("innerHTML", 'Please confirm that you are human'); } // reset captcha if (grecaptcha.getResponse()) { grecaptcha.reset(); } } }); }); })(jQuery); A slightly improved version.

Comments

3 shown
dennetmol 2016-06-23T12:21:00+00:00

I have exactly the same problem. Anyone a solution? thanks!

andriusrimkus 2016-08-23T14:01:00+00:00

This is my solution to the problem: (function($) { $(document).ready(function() { jQuery(".ninja-forms-form").on('submitResponse.resetCaptcha', function(e, formData, jqForm, options){ if (grecaptcha && grecaptcha.getResponse()) { grecaptcha.reset(); } }); }); })(jQuery); It resets the captcha state (if it was activated) after submitResponse event. This is a solution for ajax powered form.

andriusrimkus 2016-08-23T17:00:00+00:00

(function($) { $(document).ready(function() { jQuery(".ninja-forms-form").on('submitResponse.resetCaptcha', function(e, formData, jqForm, options){ if (typeof grecaptcha !== 'undefined') { // add error manually if captcha isn't solved if (!grecaptcha.getResponse()) { jQuery("#ninja_forms_field_8_error").prop("innerHTML", 'Please confirm that you are human'); } // reset captcha if (grecaptcha.getResponse()) { grecaptcha.reset(); } } }); }); })(jQuery); A slightly improved version.