After some fraud attempts, I've been requested to add a Captcha to an Ubercart store in Drupal 7 and am surprised that in my searching I can't find any information on how to do this. Has anyone achieved this?
1 Answer
I am assuming you are talking about the add to cart form. Please share on what page or place you need captcha?
If you cannot find a module, then you need to do exactly what the captcha module does,
- Write hook_fomr_FORM_ID_alter for the form for which you need to add the captcha.
- Look for articles online explaining how to add captcha programmatically on a form in Drupal, ex: How do I add reCaptcha to a custom form?, https://www.drupal.org/node/743056.
- Enable your custom module containing this code, and the captcha module.
You should have your captcha on ubercart's add to cart or any other form with a submit button.
-
Thanks -- working through with the person that requested it how much value a Captcha has on a multi-page checkout process but will accept this as the answer and may need to implement it pending outcome.– LarynCommented Jan 15, 2016 at 18:14