Template:Date Counter/doc
This template returns the number of months, weeks and days that have elapsed between two dates.
You can use these for use in {{Infobox conflict}} to signify how long a war lasted.
Contents
Usage[edit]
Use the format below for an event that has a start and a finish:
-
({{Date Counter |month1 = |day1 = |year1 = |month2 = |day2 = | year2 = }})
Use the formation below to calculate elapsed time since a past date / ongoing:
-
({{Date Counter |month1 = 1 |day1 = 1 |year1 = 1 }})→ 2016 years, 1 month and 1 day
Alternatively, the first set of parameters can be left out to get the time left until a future date:
-
({{Date Counter |month2 = 1 |day2 = 15 |year2 = 2018 }})→ 11 months, 1 week and 6 days
Note: Take out the brackets if you do not want them.
Examples[edit]
Start and a finish[edit]
({{Date Counter |month1 = 02 |day1 = 07 |year1 = 2014 |month2 = 06 |day2 = 16 | year2 = 2016 }})
(2 years, 4 months, 1 week and 2 days)
Elapsed time / An ongoing event[edit]
— This counter will increase daily until you add the 'Finish' fields (like above)
({{Date Counter |month1 = 02 |day1 = 07 |year1 = 2014}})
(2 years, 11 months, 3 weeks and 5 days)
Time left until a future date[edit]
— This counter will increase daily until you add the 'Finish' fields (like above)
({{Date Counter |month2 = 11 |day2 = 15 |year2 = 2019}})
(2 years, 9 months, 1 week and 6 days)