Basic Conditional Actions
This page will explain how the conditional system works in ez Form Calculator for WordPress. The plugin allows you to perform the following actions:
- Show or hide elements (or the submit button)
- Set values dynamically
- Activate or deactivate elements
- Redirect the user to a different page (or any other URL)
- Set email targets depending on the value
By default, each conditional element compares their value with the compare value. If the condition is true, the conditional action will be performed and the respective counter-action will be performed automatically.
Multiple Conditional Actions on a Single Element
Since multiple conditional actions could cancel each other if applied on a single element, the advanced option No auto toggle comes to the rescue.
Many conditional actions will perform their opposite conditional action in case the condition is not true. For example, if a conditional action shows an element if a condition is true, it will hide the element if the condition is not true. To prevent this, you’d want to disable the opposite action as shown in the following screenshot:
Since v126.96.36.199, dates can be compared in the conditional system. The syntax of the compare value is fixed and should match the following format:
The below conditions work like this:
- Set the value of Numbers to 10 if the date of Datepicker is equal or after March 1st, 2020
- Set the value of Numbers to 0 if the date of Datepicker is before March 1st, 2020
The conditions would look like this in the form editor: