Template:Time/doc/parameters

From The Goon Show Depository

< Template:Time‎ | doc

Revision as of 07:11, 31 August 2022 by Kurt (talk | contribs) (1 revision imported)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

Parameters

Lua error in Module:Template_link_general at line 144: attempt to concatenate local 'titlePart' (a nil value). supports two positional and several named parameters; none are required:

|<time zone> – the first positional (unnamed) parameter, specifies the time zone for which the template is to provide a time output. If omitted, the template displays UTC time. A time zone is identified by an abbreviation of the time zone's standard-time name. Do not use a summertime or daylight saving time abbreviation; they will be ignored and produce an error message.
|<df> – the positional (unnamed) version of |df= which see
|df= – date format; this parameter takes one of several values; values other than these are ignored:
|df=dmy – specifies day month year date format; time in 24-hour format; alias: |df=dmy24
03:47, 27 December 2024 MST [refresh]
|df=dmy12 – same as |df=dmy except time in 12-hour am/pm format
3:47 am, 27 December 2024 MST [refresh]
|df=mdy – specifies month day, year format; time in 24-hour format; default when a date format is not specified in the time zone's properties; alias: |df=mdy24
03:47, December 27, 2024 MST [refresh]
|df=mdy12 – same as |df=mdy except time in 12-hour am/pm format
3:47 am, December 27, 2024 MST [refresh]
|df=iso – renders the date/time in a form roughly adhering to the ISO 8601 format (seconds omitted)
2024-12-27T03:47 MST [refresh]
|df=y – legacy Lua error in Module:Template_link_general at line 144: attempt to concatenate local 'titlePart' (a nil value). parameter, same as |df=dmy
|df=12 – time-only display 12-hour am/pm format
3:47 am MST [refresh]
|df=24 – time-only display 24-hour format
03:47 MST [refresh]
|df-cust= – custom time/date formats using the codes defined at mw:Help:Extension:ParserFunctions##time; yields to |df=
|df-cust-a= – custom time/date formats as above specifically for ante meridiem time; requires |df-cust-p=; yields to |df-cust=
|df-cust-p= – custom time/date formats as above specifically for post meridiem time; requires |df-cust-a=; yields to |df-cust=
|dst= – when set to no, disables the daylight saving time calculation for the time zone; other values ignored; useful for locations within a time zone that do not observe daylight saving time; Arizona, for example
|lang=<code> – displays time/date in language specified by ISO 639 language <code>
these parameters take only the value yes:
|dateonly= – suppresses time display
|timeonly= – suppresses date display
|hide-refresh= – suppresses the refresh link
|hide-tz= – suppresses the timezone abbreviation
|unlink-tz= – renders unlinked timezone abbreviation
|_TEST_TIME_= – a parameter that was useful during the development of the template's code. The value assigned to this parameter must either be in ISO 8601 format without time zone designator (2024-12-27T10:47:37), or YYYYMMDDhhmmss format as output by {{Timestamp}} (20241227104737). This is interpreted by the template as UTC.