Snaptcha compatibility
Closed this issue · 1 comments
Hi!
We're having real trouble with the Snaptcha plugin and the cookie-consent plugin.
Would you be able to add: public $enableSnaptchaValidation = false; to your controller please as per their docs? - https://putyourlightson.com/plugins/snaptcha#disabling-validation
Many thanks!
Hi!
We would like to not include support for other third party plugins directly in our source code, but rather give the developers the tools to solve these challenges by customizing the plugin.
The snaptcha issue can be solve by supplying your own template for the cookie consent banner. What you need to do is copy the file vendor/elleracompany/craft-cookie-consent/src/templates/banner.twig
to your craft template folder. As an example, you can call it _banner.twig
and save it in the root of your template folder. Then update the site settings accordingly
.
You can now add {{ craft.snaptcha.field }}
to the template (inside the form tags, so on line 3 for instance) and the snaptcha will work for the cookie consent plugin as well.