• Resolved JonLimitless

    (@jonlimitless)


    Hello,

    This is more report on an issue with how WPForms Lite creates v2 reCaptcha and how it can cause issues for some people.

    Issue: The hidden input field (g-recaptcha-hidden) generated for reCaptcha v2 that gets added when selecting v2 reCaptcha comes with a “required” attribute that does not get validated by WPForms on check or before form submission.

    Followed Process:
    – Error occurs on fresh install of WordPress with only WPForms Lite, no other plugins and no themes are installed.
    – WPForms Lite settings are edited to use “Checkbox reCAPTCHA v2” using a credentials for reCaptcha v2.
    – A new form is created from scratch trying only 1 field and multiple fields then recaptcha is enabled and saved. (This was tested making one from a template using only 1 field and multiple fields.)
    – When the form is placed on to a page, trying to submit the form the reCaptcha field itself gives an error message “This field is required.” below the checkbox. Note: This happens if you check the reCaptcha field or not as a part of html5 form validation and was tested using both.
    – This was then tested across 3 different browsers on 2 different computers.

    Fix:
    Remove the “required” attribute from the field named “g-recaptcha-hidden” in includes/class-frontend.php.

    Notes:
    This attribute ‘required’ on a field forces it to be filled in EXCEPT this is a hidden input field and no javascript is filling before/on submission. If something should be interacting with the field then it may be removed/broken from the current release of the plugin. Overall you should not need the “required” attribute on this field as the validation is done through Google reCaptcha and revalidated on form submission.

    Hope this helps and have a great day,
    – Jon Long

Viewing 1 replies (of 1 total)
  • Hi @jonlimitless,

    Thanks for reaching out to us with this feedback. The information you’ve shared is going to be looked at by our team and followed up on.

    If you have any further concerns, please don’t hesitate to contact us.

    Kindly,

Viewing 1 replies (of 1 total)

The topic ‘Incorrectly Set WPForms Recaptcha Input Field’ is closed to new replies.