How to Use Advanced Form Validation in WordPress Forms
Advanced form validation prevents spam and bot submissions and provides more specific form entries according to your requirements. In this feature, you can apply multiple conditions to dictate whether there’s an error in the entries or whether the entries are true. And depending on whether the conditions are met, the submission will proceed or fail.
Use case
You can set boundaries on the entries for different form fields. The boundaries determine whether the entries are acceptable or not.
How to use advanced form validation in WordPress forms
For this tutorial, we will be using Fluent Forms, a WordPress contact form.
Step 1:
Go to the Settings of the form to which you want to apply advanced form validation.
Step 2:
From the Settings and Integrations page, go to Settings → Advanced Form Validation. Check the box for Enable Advanced Form Validation below Status.
Step 3:
Add one or more conditions based on your need.
To add conditions, select the desired form field in the first box and the desired option/answer in the last box. The box in the middle dictates the relation between them, whether the question in the first box is equal to/ not equal to/ starts with/ ends with/ includes/ doesn’t include the content in the last box.
To add more conditions, click on the Plus icon.
In case of multiple conditions, select All if you want to proceed/fail submission when all the conditions are met. Select Any if you want the submission to proceed/fail when any of the conditions are met.
For example, if a company only delivers inside the US and doesn’t take orders unless the minimum order quantity is 10, their validation conditions will look like the image above.
Step 4:
Select Validation Type by checking a radio box to determine whether to fail the submission or let the submission proceed when the conditions are met.
Step 5:
Write an error message to show if the submission fails.
Step 6:
Lastly, click on Save Notification at the bottom of the page to save your advanced validation.
Related features
Empty submission blocking
Blank form submissions compromise the number of form submissions. From the number of entries, you can’t tell how many of them are of value to your business. You can restrict blank form submissions to prevent that from happening.
Double opt-in feature
When you enable the double opt-in feature, an email is sent automatically after a form submission to the email address provided in the form. After primary submission, the client receives a message to check their email to confirm their submission. The email asks the client to click a button to confirm their form submission. This feature prevents forms with fake email addresses from being submitted.
Sarika writes for FluentForms and loves to offer insights into small businesses. She’s curious and enjoys discussing ideas, interests, and perspectives. In her free time, she’s either marvelling at architectural beauties or trying different cuisines.
Leave a Reply
You must be logged in to post a comment.