UndefinedOffset / silverstripe-nocaptcha

A spam protector and form field using Google's reCAPTCHA v2 or optionally a foundation v3 implementation
BSD 3-Clause "New" or "Revised" License
31 stars 37 forks source link

Captcha is not showing in custom form please help #51

Closed Bandnakalra closed 4 years ago

UndefinedOffset commented 5 years ago

are you calling enableSpamProtection() on the custom form as defined in the docs for the spam protection module (and in this one if I remember right) https://github.com/silverstripe/silverstripe-spamprotection#configuring ? Can you post some additional info like how the form is being constructed and your yaml config where you are setting the spam protector?

Bandnakalra commented 5 years ago

now the captcha is showing but i am getting error "Captcha is required" after submitting form

UndefinedOffset commented 5 years ago

Make sure you do not set the captcha to required, I know it sounds counter intuitive it's always required, that could be the issue there.

Bandnakalra commented 5 years ago

I am getting js error in console
Cannot set property 'value' of null at DrawCaptcha

Actually nocaptcha was taking path of its js file in my public/ resources/nocaptcha

so i put the js file in my public folder and captcha started showing up but now form submit getting error

UndefinedOffset commented 5 years ago

hmm what style of Recaptcha are you using and what version of this module are you using. As well are you using jQuery validate?