Honeypot anti-spam feature for formbuilder

  Previous article Next article  

Honeypot anti-spam feature for formbuilder

  Article optimized for CMSMS 2.x

  Author:
  Last tested in: CMSMS 2.2.5
  Last updated: 18-11-2017
  Comments: 0
  http://cms.ms/XsvN

In this tutorial I will show you how Velden a honeypot anti-spam feature added to a Form Builder form in CMS Made Simple. The idea is that automated web bots only look for the form fields and can't resist to add some information. As the specific field is hidden from real, human visitors you know it should never contain anything.

  How to use

Step 1: The webform

Open your form in the Form Builder Admin page and add a new field:

  • Text Input:
    Name: website
    Require a response for this Field: NOT(!) checked
    Field Validation: Doesn't match Regular Expression
    Advanced Settings tab:
    Field Alias and DOM id (CSS id) attribute: frm_website
    CSS Class for this field: website
    Validation Regex: /.+/

Test it by filling in the form and check that it does not validate when anything is filled in 'website' field. Then fill in the other field and leave 'website' empty and check that the Submission template text is displayed and the form is received by the recipient supplied in the form.




Step 2: Hide the website field

Use some css to hide the 'website' field from the website visitor. Add to your (form) stylesheet:

div.website, div.website * {
  display: none !important;
}

The website field should now not be visible anymore.




CMS Made Simple 2.2.5 - Tutorials, tips and tricks - CMSMS 2.2.5

Honeypot anti-spam feature for formbuilder

  Article optimized for CMSMS 2.x

  Author:
  Last tested in: CMSMS 2.2.5
  Last updated: 18-11-2017
  Comments: 0
  http://cms.ms/XsvN