ConPresso uses the PHP-function date() for outputtings dates. This function allows the use of the characters listed in the following table. The frontend output of the names of days and months is determined by the rubric language you have selected.
Table A.1. Date Placeholders
Format Character | Description | Example Return Value |
---|---|---|
a | lower case: Ante Meridiem or Post Meridiem | am or pm |
A | upper case: Ante Meridiem or Post Meridiem | AM or PM |
B | Swatch-Internet-Time | 000 to 999 |
c | ISO 8601 date (added to PHP 5) | 2004-02-12T15:19:21+00:00 |
d | Day of month, two digits with leading zero | 01 to 31 |
D | Day of week, shortened to three characters | Mon to Sun |
F | Full name of month, e.g. January or March | January to December |
g | 12 hour format, without leading zeros | 1 to 12 |
G | 24 hour format, without leading zeros | 0 to 23 |
h | 12 hour format, with leading zeros | 01 to 12 |
H | 24 hour format, with leading zeros | 00 to 23 |
i | Minutes with leading zeros | 00 to 59 |
I (großes i) | Date in summer season / DST | 1 in summer season/DST, otherwise 0 |
j | Day of month without leading zeros | 1 to 31 |
l (lower case 'L') | Full name of day | Monday to Sunday |
L | Leap year or not | 1 for leap year, otherwise 0 |
m | Month as number with leading zeros | 01 to 12 |
M | Name of month shortened to three characters | Jan to Dec |
n | Month as number without leading zeros | 1 to 12 |
O | Time difference to Greenwich time (GMT) in hours | example: +0200 |
r | RFC 2822 formatted date | example: Thu, 21 Dec 2000 16:01:07 +0200 |
s | Seconds with leading zero | 00 to 59 |
S | Suffix for English day of months, two characters st, nd, rd or th. Use combined with j recommended. | |
t | Number of days of month | 28 to 31 |
T | Time zone setting of computer | examples: EST, MDT ... |
U | Seconds since begin of UNIX-epoch (January 1 1970 00:00:00 GMT) | |
w | Number of day in week | 0 (for Sunday) to 6 (for Saturday) |
W | ISO-8601 calendar week, week starting on monday | example: 42 (the 42th week of the year) |
Y | Year, four digits | example: 1999 or 2003 |
y | Year, two digits | example: 99 or 03 |
z | Number of day of the year | 0 to 365 |
Z | Offset of timezone in seconds. The offset of UTC timezone west is negative and for UTC timezone east it is positive. | -43200 to 43200 |
Example A.1. Date Formatting
Day of the week only: l
Year-month-day: Y-m-d
Hours:minutes: H:i
Default Value: Y-m-d H:i