Datepicker Support
When using the Date Field (Shopify Datepicker) field type with presets, you can add a date format, which will save the value of your order attribute to a set format after selecting a date from the calendar.
Examples:-YYYY-MM-DD
will format to 2023-12-24
ddd DD MMM YY
will format to Sun 13 Dec 67
The tokens that represent the different date parts are shown below.
Date Part | Token | Example output |
---|---|---|
Month | M | 1 2 ... 11 12 |
MM | 01 02 ... 11 12 | |
MMM | Jan Feb ... Nov Dec | |
MMMM | January February ... November December | |
Day of Month | D | 1 2 ... 30 31 |
DD | 01 02 ... 30 31 | |
Day of Week | ddd | Sun Mon ... Fri Sat |
dddd | Sunday Monday ... Friday Saturday | |
Year | YY | 70 71 ... 29 30 |
YYYY | 1970 1971 ... 2029 2030 | |
Hour | H | 0 1 ... 22 23 |
HH | 00 01 ... 22 23 | |
h | 1 2 ... 11 12 | |
hh | 01 02 ... 11 12 | |
Minute | m | 0 1 ... 58 59 |
mm | 00 01 ... 58 59 | |
Second | s | 0 1 ... 58 59 |
ss | 00 01 ... 58 59 | |
AM/PM | A | AM PM |
a | am pm |