This plugin requires the Gravity Forms plugin, which is a commercial product sold separately by Rocketgenius, Inc. It does nothing on its own.
Date Picker Blocker for Gravity Forms restricts which dates visitors can pick in a Gravity Forms date field. It grew out of the needs of travel businesses, built around real client work at Paxrank, where managing product availability usually calls for finer control than a plain date field offers. That said, nothing about it is travel-specific: it works just as well for any kind of business.
The plugin is completely free, and I have no plans to charge for it. Feel free to use it and adapt it however suits you best. Have a suggestion, or found a bug? Report it in the support forum or through the website, and I will look into it as soon as I get a chance.
Three kinds of restriction
- Blocked dates and ranges. Block a single day, or a whole range in one record by giving it a start and an end date.
- Minimum advance notice. Require bookings to be made at least a set number of days ahead, from 0 to 365. Dates in the past are always blocked, regardless of this setting.
- Weekdays. Block one or more days of the week — for example every Sunday.
Three levels of scope
Every restriction can be applied globally to all forms, to one specific form, or to one specific date field on one form.
The two ways scopes combine are deliberately different, because the rules mean different things:
- Advance notice resolves by priority. The most specific restriction wins — field, then form, then global — and they do not stack.
- Weekday restrictions are additive. Every applicable restriction is combined, so the blocked days add up.
Other things it does
- Works with all Gravity Forms date field types: date picker, plain text input, and the day/month/year dropdown variant.
- Server-side validation parses each submitted date using that field’s own Gravity Forms date format, so a field configured differently from the rest of the site still validates correctly.
- A global date format setting (DD/MM/YYYY, MM/DD/YYYY, YYYY-MM-DD and dashed variants) controls how dates are shown and entered in the admin.
- Every restriction can carry a description, and the list shows who created it and when.
- Uninstall is opt-in. Your data is kept unless you explicitly tick the box that deletes it.
- Fully translatable, with translations delivered through translate.wordpress.org.
Developer hooks
do_action( 'paxrank_gf_date_blocker_init' );
apply_filters( 'paxrank_gf_date_blocker_should_load', bool $should_load );