Template:Event timer/doc: Difference between revisions

Jump to navigation Jump to search
cats; more caveats; minor changes; remove wip
(date formats, note on cache purging. wip)
(cats; more caveats; minor changes; remove wip)
Line 24: Line 24:
=== Dates ===
=== Dates ===


The template uses parser function <nowiki>{{#time: }}</nowiki>, which can intepret several different date formats. At least the following formats work in the template:
The template uses parser function <nowiki>{{#time: }}</nowiki>, which can interpret several different date formats. At least the following formats work in the template.


{| class="wikitable"
{| class="wikitable"
Line 51: Line 51:


<small><references group="note"/></small>
<small><references group="note"/></small>
=== Further notes ===
The template operates using UTC time. As such, the day will change at midnight UTC, which might be different from the midnight in your location.
The template doesn't understand time periods that start and end different years, e.g. 25 Dec to 17 Jan. If the new year's day is between the start date and the end date, you need to call the template twice.


== Examples ==
== Examples ==
Line 78: Line 84:
{{Event timer | Start = 23 Sept | End = 22 Dec | Message = '''It's autumn in the Northern Hemisphere on Earth accoring to the astronomical definition.''' | Today = 10 Oct}}
{{Event timer | Start = 23 Sept | End = 22 Dec | Message = '''It's autumn in the Northern Hemisphere on Earth accoring to the astronomical definition.''' | Today = 10 Oct}}


But if on 4th July and 25th December, we will see nothing.
But on 4th July and 25th December, we will see nothing.


{{Event timer | Start = 23 Sept | End = 22 Dec | Message = '''It's autumn in the Northern Hemisphere on Earth accoring to the astronomical definition.''' | Today = 25 Dec}}
{{Event timer | Start = 23 Sept | End = 22 Dec | Message = '''It's autumn in the Northern Hemisphere on Earth accoring to the astronomical definition.''' | Today = 25 Dec}}
Line 102: Line 108:
On 26th October, we will see this:
On 26th October, we will see this:
{{Event timer | Start = 26 Oct | End = 26 Oct | Message = <div style="width: 80%; margin:auto; text-align: center; border: 3px double blue; background-color: lightsteelblue; font-size: 20px">Happy birthday, Jovenan!</div>  | End message = '''Jovenan's birthday has passed.''' | Future message = '''It's not yet Jovenan's birthday'''| Today = 26 Oct}}
{{Event timer | Start = 26 Oct | End = 26 Oct | Message = <div style="width: 80%; margin:auto; text-align: center; border: 3px double blue; background-color: lightsteelblue; font-size: 20px">Happy birthday, Jovenan!</div>  | End message = '''Jovenan's birthday has passed.''' | Future message = '''It's not yet Jovenan's birthday'''| Today = 26 Oct}}
<includeonly>[[Category:Templates]]</includeonly>
<noinclude>[[Category:Documentation subpages]]</noinclude>
1,769

edits

Navigation menu