Template:Age in days/doc

From Wikimedia Commons, the free media repository
Jump to navigation Jump to search

This template returns the number of days between two dates. If the second set of parameters is not included it will calculate the days between the given date and today.

Usage

{{Age in days |year1= |month1= |day1= |year2= |month2= |day2= }}

Template parameters

ParameterDescriptionDefaultStatus
year1
1
year 1year of 1. dateemptyrequired
month1
2
month 1month of 1. dateemptyrequired
day1
3
day 1day of 1. dateemptyrequired
year2
4
year 2year of 2. datecurrent year, e.g.: 2024optional
month2
5
month 2month of 2. datecurrent month, e.g.: 06optional
day2
6
day 2day of 2. datecurrent day, e.g.: 21optional

Additional information

The template is intended to be used in the following namespaces: no namespace specified

The template is intended to be used by the following user groups: no user group specified

Examples

{{Age in days|2007|5|24|2008|4|23}}

renders as:

335


{{Age in days|2007|5|24}}

renders as:

6238

Localization

This template is not intended to be localized.