Jump to content

Template:Age in years

From NicheWork
Revision as of 03:11, 28 February 2018 by w>Johnuniq (replace with code to invoke Module:Age to improve consistency and error checking for the age templates)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

0

Template documentation

Usage

{{Age in years|2000}} yields 25–26.

{{Age in years|2000|2015}} yields 14–15.

{{Age in years|2000-06-01|2015-06-01}} yields 15.

{{Age in years|2000-06-02|2015-06-01}} yields 14.

{{Age in years|2000-01-01}} yields 26.

{{Age in years|2000-12-31}} yields 25.

Note that the template provides an age range if a year and not a full date is given: during the year 2015, someone born in 2000 is either 14 or 15 years old, depending on whether they have passed their birth date in the later year. If no end date is given then the current date is used.

See also