A field containing a user-selected date
| Name | Type | Description |
| is_valid | Boolean | True if the value is not empty |
| value | String | Unformatted date string (in UTC) |
| date | time | An object containing more detailed information about the selected date |
| default_value | String | The default value for this field if no value is specified |
| field_id | String | The identifier for this field |
| label | String | The label for this field |
| output | String | The value formatted using the "Short date pattern" (MM/dd/yyyy). May include additional markup in the editor preview to make it easier to edit content |
Field used to store a date. All dates are stored in UTC time.
Should be used to display a date field inside a form.
| Name | Type | Description |
| is_valid | Boolean | Will always be true |
| type | String | Will always be "date" |
| default_value | time | Optional. The default value to use for this date field when the form is displayed. Will be null if there is no default value |
| map_to_attribute | String | If the user is signed into a profile when they submit this form and map_to_attribute is set, the profile attribute specified in map_to_attribute will be set to the value of this field. This should also be used to override the default value if the user is signed into a profile and the specified attribute has already been set |
| required | Boolean | Will be true if the user is required to enter a date before submitting the form |
| required_message | String | The message to display when the user attempts to submit the form without entering a date |
| validators | validators | The list of validators that should be used to validate this date field, if applicable |
| element_id | String | A helper property containing a unique ID for this field on this instance of this form. This value should be different every time the form is output |
| subtext | text | Help or hint text to display together with the field |
| condition | condition | The condition that should be used to show and hide this form field |
| classname | String | CSS class name(s) to be applied to the field |
| field_id | String | The identifier for this field |
| label | String | The label for this field |
| output | String | Default HTML markup for this date field, which makes a number of assumptions about other elements on the page that may or may not be included. Developers should avoid using the default output in order to guarantee that forms work as expected, including styling, validation, conditionals, and more. May include additional markup in the editor preview to make it easier to edit content |
Use the add_seconds, add_minutes, add_hours, add_days, add_weeks, add_months, and add_years filters to manipulate dates.
Use math to manipulate dates
Copyadd_seconds
add_minutes
add_hours
add_days
add_weeks
add_months
add_years
You can use the date filter either to create a date object or to format a date as a string.
Many ways to use the date filter
Copycreate a date object
Defaults to the current date
format a date as a string
Entity Date Opened with Date Filter
CopyDate Opened: {{ entity.date_opened | date: "MMMM dd, yyyy" }}
{% endif %}Assign date add month and fetch calendar_entries
CopyVar date assignment and date math
CopyFormat dates using standard or custom .NET date formats.
Format Dates
CopyTime advanced
CopyTo timezone filter
CopyReturns the input as a date. If format is specified, converts the date to a string before returning it using the given format. The format must be a valid standard or custom .NET date format.
date: String format
You can use the date filter either to create a date object or to format a date as a string.
Many ways to use the date filter
Copycreate a date object
Defaults to the current date
format a date as a string
If format is unspecified, returns a time_diff object describing the difference between the current date and the other date. If format is specified, converts the time difference to a string before returning it using the given format. If supplied, the format must be a valid standard or custom.NET TimeSpan format.
time_diff: time otherString format
Format time diffs using standard or custom.NET TimeSpan formats.
Format Time Diffs
CopyTime diff
CopyReturns the timezone that the date is in. If full is true or if an abbreviated timezone name is not available, returns the full timezone identifier (eg: "Europe/Rome"). If full is false (default) or not specified and an abbreviated timezone name is available returns the abbreviated timezone name (eg: "PST" or "PDT").
timezone: Boolean full
Use the timezone filter to output the timezone used by a date object. The output may either be the full timezone identifier or the shortened timezone abbreviation.
Using the timezone filter
CopyConverts a date to the specified timezone.
to_timezone: String timezone
Use the to_timezone filter to convert a date to a specific timezone.
Using the to_timezone filter
CopyReturn a date object operand minutes in the future from the input date.
add_minutes: Integer operand
Use the add_seconds, add_minutes, add_hours, add_days, add_weeks, add_months, and add_years filters to manipulate dates.
Use math to manipulate dates
Copyadd_seconds
add_minutes
add_hours
add_days
add_weeks
add_months
add_years
Return a date object operand years in the future from the input date.
add_years: Integer operand
Use the add_seconds, add_minutes, add_hours, add_days, add_weeks, add_months, and add_years filters to manipulate dates.
Use math to manipulate dates
Copyadd_seconds
add_minutes
add_hours
add_days
add_weeks
add_months
add_years
Return a date object operand months in the future from the input date.
add_months: Integer operand
Use the add_seconds, add_minutes, add_hours, add_days, add_weeks, add_months, and add_years filters to manipulate dates.
Use math to manipulate dates
Copyadd_seconds
add_minutes
add_hours
add_days
add_weeks
add_months
add_years
Return a date object operand weeks in the future from the input date.
add_weeks: Integer operand
Use the add_seconds, add_minutes, add_hours, add_days, add_weeks, add_months, and add_years filters to manipulate dates.
Use math to manipulate dates
Copyadd_seconds
add_minutes
add_hours
add_days
add_weeks
add_months
add_years
Return a date object operand hours in the future from the input date.
add_hours: Integer operand
Use the add_seconds, add_minutes, add_hours, add_days, add_weeks, add_months, and add_years filters to manipulate dates.
Use math to manipulate dates
Copyadd_seconds
add_minutes
add_hours
add_days
add_weeks
add_months
add_years
Return a date object operand days in the future from the input date.
add_days: Integer operand
Use the add_seconds, add_minutes, add_hours, add_days, add_weeks, add_months, and add_years filters to manipulate dates.
Use math to manipulate dates
Copyadd_seconds
add_minutes
add_hours
add_days
add_weeks
add_months
add_years
Return a date object operand seconds in the future from the input date.
add_seconds: Integer operand
Use the add_seconds, add_minutes, add_hours, add_days, add_weeks, add_months, and add_years filters to manipulate dates.
Use math to manipulate dates
Copyadd_seconds
add_minutes
add_hours
add_days
add_weeks
add_months
add_years