- Jotform User Guide
- Advanced Features
- How to Use the Date Limits Option
Last Update: May 13, 2022
Would you like to set limits on your Date Picker? For example, you only want to allow your users to enter dates that fall on a weekend. That is now possible with the new advanced options added to the default Date Picker element.
First, add the Date Picker element to your form then click the gear icon. In the properties panel, go to the Limits tab.
Here’s the complete list of options that you can use on disabling dates:
- Age Verification – prevents users under a certain age from submitting the form.
- Past & Future – enable the Past option if you want to allow users to select past dates. The same goes with the Future option, enable it if you want to allow future dates to be selected.
- Days of the week – unchecking a day will disable all of the same days in the calendar. You can uncheck which day of the week you don’t want your users to select in the date field. So, to only allow weekdays, uncheck Saturday and Sunday.
- Start & End Date – disable dates within the range you set up. This will only allow selection between the dates you selected.
- Disable Custom Dates – here you can disable specific dates. The correct format is YYYY-MM-DD but you may also use MM-DD or just DD. Examples:
- 2017-07-30 disables July 30, 2017
- 07-01 disables July 1st of each year
- 15 disables the 15th of each month
- Disable Date Ranges – this is similar to the Start & End Date option but this allows you to set multiple date ranges to disable. This is also a good way to filter out invalid dates. For example, to have users not enter invalid years like “192” or years before 2000, set the date range to “0000-01-01>2000-01-01”.
Dynamic Date Selections
You can achieve this by utilizing the Start & End Date limit and using…
today+{n}where {n} is the number of days to be added to today.
Say, you’re working on a booking form and would like to limit the booking dates to be at least 1 week after submission, and at the same time, you want to limit the booking window to just 1 week. For this to happen, you need to set the Start Date to “today+7” [1 week after] and the End Date to “today+13” [a window of just 1 week].
Comments and suggestions are welcome below. If you have a question, post it in our Support Forum so we can assist you.
We're sorry to hear that. What problem did you have with the guide?
How can we improve this guide?