Difference between revisions of "Template:Countdown to anniversary/doc"

From blackwiki
Jump to navigation Jump to search
imported>Renamed user awfwvowjvwrvnwio
imported>Renamed user awfwvowjvwrvnwio
m (→‎Examples: minor typo)
Line 28: Line 28:
 
{{Countdown to anniversary|2002|2|8|It's my birthday!|19|35|0}}
 
{{Countdown to anniversary|2002|2|8|It's my birthday!|19|35|0}}
  
<code><nowiki>{{</nowiki>[[Template:Countdown to anniversary|Countdown to anniversary]]<nowiki>|2004|8|10|It's my siter's birthday!|13|2|0}}</nowiki></code> gives:
+
<code><nowiki>{{</nowiki>[[Template:Countdown to anniversary|Countdown to anniversary]]<nowiki>|2004|8|10|It's my sister's birthday!|13|2|0}}</nowiki></code> gives:
  
 
{{Countdown to anniversary|2004|8|10|It's my sister's birthday!|13|2|0}}
 
{{Countdown to anniversary|2004|8|10|It's my sister's birthday!|13|2|0}}

Revision as of 06:53, 3 August 2016

Usage

Usage: {{Countdown to anniversary|year|month|day|msg|hour|minute|second}},

where year, month and day represent the target date and hour, minute and second specify the respective components of the date-time to count down to.

hour, minute and second are not required.


Examples

{{Countdown to anniversary|2002|2|8|It's my birthday!}} gives:

Error: year, month, and day must be specified

{{Countdown to anniversary|2002|2|8|It's my birthday!|19|35|0}} gives:

Error: year, month, and day must be specified

{{Countdown to anniversary|2004|8|10|It's my sister's birthday!|13|2|0}} gives:

Error: year, month, and day must be specified

{{Countdown to anniversary|2004|2|29|The next 29th of February is 1461 days away.|12|0|0}} gives (example of leapling):

Error: year, month, and day must be specified

No description.

Template parameters

This template prefers inline formatting of parameters.

ParameterDescriptionTypeStatus
11

Target date's year

Default
2002
Example
2002
Numbersuggested
22 1 2 3 4 5 6 7 8 9 10 11 12

Target date's month

Default
2
Example
2
Numbersuggested
33 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31

Target date's day of month

Default
8
Example
8
Numbersuggested
44

Message to show during the anniversary.

Default
It's my birthday!
Example
It's my birthday!
Stringoptional
55 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23

When not in a birthday, the hour (from 0 to 23) of the date-time to count down to.

Default
0
Example
19
Numberoptional
66 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59

When not in a birthday, the minute (from 0 to 59) of the date-time to count down to.

Default
0
Example
35
Numberoptional
77 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59

When not in a birthday, the second (from 0 to 59) of the date-time to count down to.

Default
0
Example
0
Auto value
0
Unknownoptional