Sale!

Gravity Forms Limit Checkboxes Perk 1.2.1

$54.00 $6.80

Want a discount? Become a member by purchasing Quarterly Plan!

Description

Gravity Forms Limit Checkboxes

Version 1.2.1
License GPL
Developer Gravity Perks
Released 04/25/2017

The Gravity Forms Limit Checkboxes perk allows you to limit how many checkboxes of a checkbox field may be selected at any given time. This perk supports specifying a minimum and maximum limit per checkbox field and also allows you to span one field’s limits across multiple fields!

How does it work?

This perk loads a little Javascript which keeps track of how many checkboxes have been checked per field. Once the maximum limit has been reached for a specific field or a group of fields with a shared limit, the rest of the unchecked checkboxes are disabled and not check-able. Unchecking one of the currently checked checkboxes (thereby bringing the number of checked checkboxes under the limit) will make the previously disabled checkboxes check-able.

When a limit is spanned across multiple checkbox fields, all checked checkboxes in those fields will count towards the specified limit. For example, if you have two checkbox fields with a shared limit of two (2), you will be able to select two checkboxes from a single field or one checkbox in each field.

The minimum limit is validated when the form is submitted. If the user did not select enough checkboxes it will return a validation error with the minimum number of checkboxes that must be checked.

How do I enable this functionality?

Let’s start with setting a minimum and maximum limit on a single checkbox field.

  1. Create a new Gravity form or go to edit an existing Gravity form.
  2. Create a new Checkbox field or open an existing Checkbox field to modify its settings.
  3. Navigate to the “Perks” tab (most often adjacent to the “Advanced” tab).
  4. Check the “Limit how many checkboxes can be checked” checkbox.
  5. Specify a minimum and/or maximum limit in the respective text input fields.

Spanning limits across multiple fields

If you would like to span a limit across multiple fields, follow the above instructions to set the base limits and then follow the below instructions to enable the spanned limit functionality and select which fields the limit should be spanned across.

  1. Check the “Span limit across multiple checkbox fields” checkbox.
  2. Select each field that should share the base limits specified for the current field from the drop down which appears after enabled the “Span limit across multiple checkbox fields’ option.

Done!

Product Enquiry