Àdàkọ:Age in years, months, weeks and days
(Àtúnjúwe láti Àdàkọ:Age in months, weeks and days)
This template uses Lua: |
This template returns the number of months, weeks and days that have elapsed between two dates.
Usage
{{Age in years, months, weeks and days |month1 = |day1 = |year1 = |month2 = |day2 = | year2 = }}
Note that all parameters default to the current date, so for example, the second set of parameters can be left out to calculate elapsed time since a past date:
{{Age in years, months, weeks and days |month1 = 1 |day1 = 1 |year1 = 1 }}
→ 2023 years, 10 months and 6 days
Or simply, using the simpler parameter names, compatible with {{Age in years, months and days}}:
{{Age in years, months, weeks and days |month = 1 |day = 1 |year = 1 }}
→ 2023 years, 10 months and 6 days
Alternatively, the first set of parameters can be left out to get the time left until a future date, such as the next Wikipedia Day:
{{Age in years, months, weeks and days |month2 = 1 |day2 = 15 |year2 = 2025 }}
→ 2 months, 1 week and 1 day
See also
- Birth, death, age
- {{BirthDeathAge}} – carries out the functions of this template and all the following ones
- {{Birth date}} – displays the date and related hidden metadata
- {{Birth date and age2}} – displays birth date, plus age as of a specified date, "(aged ##)" appears after the birth date
- {{Birth year and age}} – year of birth and approximate age
- {{Birth-date and age}} – display birth date and age, accepts dates as text (15 June 1950; June 15, 1950; June 1950; etc.)
- {{Birth based on age as of date}} – displays approximate birth year and current age; used when a dated reference mentions the age of a person as of the date of publication
- {{Death date}} – displays the date and related hidden metadata
- {{Death date and age}} – same as {{Death date}}, except that "(aged ##)" appears after the death date
- {{Death year and age}} – year of death and approximate age at death
- {{Death-date and age}} – display death date and age, accepts date as text (15 June 1950; June 15, 1950; June 1950; etc.)
- Age only
- {{Age}} – age based on the number of full years between two dates (or a specified date and current date)
- {{Age nts}} – similar to the above, but will sort correctly in sortable tables
- {{Age in years and days}} – full years and days between two dates (or a specified date and current date)
- {{Age in days}} – age in days between two dates (or a specified date and current date)
- {{Age as of date}} – current age in years, based on a known age as of a specified date
The above documentation is transcluded from Àdàkọ:Age in years, months, weeks and days/doc. (àtúnṣe | ìtàn) Editors can experiment in this template's sandbox (create | mirror) and testcases (create) pages. Please add categories to the /doc subpage. Subpages of this template. |