Datepicker
Description
The date field allows the user to select a single date from a calendar. The date field is useful for collecting dates of birth, event dates, and other date-related information.
This field supports advanced use cases, like:
Not allowing past dates.
Setting the min date based on another date field, effectively creating a date range.
Using the date selection in calculations.
Uses
Allow people to choose their date of birth.
Allow people to choose a date for an event.
Allow people to choose a date for a reservation.
Styling
Multi-column layout: Use the layout setting under the General tab to display the field in a multi-column layout.
Hide label: Check the Hide label from view setting under the General tab to hide the label from view.
Configuration
Let’s look at the configuration options available for the date field:
Min / Max: This setting allows you to set the minimum and maximum dates that can be selected. There are four ways to configure min and max dates:
Fixed date: Specify a fixed date in yyyy-mm-dd format, like 2022-12-31.
Relative date: Select a date relative to the current date. For example, 4 would be four days from today, and -4 would be four days before today. You can use 0 under Min to disable past dates.
Field reference: Type @ to reference another date field in the form. This is useful for creating date ranges.
Math formula: This field also supports calculations which can include other fields and numbers, like
{field1 - 5}
.
Allowed days: This setting allows you to restrict the days that can be selected. You can select specific days of the week, like Monday, Tuesday, etc.
Date format: This setting allows you to choose the date format between dd/mm/yyyy and mm/dd/yyyy.