This template displays an age appropriate for an infant: months and days up to one year, years and months up to three years, and years beyond.

Usage

{{age for infant|abbr= yes/no|YEAROFBIRTH|MONTHOFBIRTH|DAYOFBIRTH}}
{{subst:age for infant|abbr= yes/no|YEAROFBIRTH|MONTHOFBIRTH|DAYOFBIRTH|CMPYEAR|CMPMONTH|CMPDAY}}
  • abbr - if set to yes days are displayed as "dys", months as "mos", etc., etc. If set to no or undefined, the template displays normally.
  • DAYOFBIRTH - the day the infant was born
  • MONTHOFBIRTH - the month in which the baby was born
  • YEAROFBIRTH - the year the baby was born, in four digits
  • CMPDAY - the day to compare to, rather than the current day
  • CMPMONTH - the month to compare to, rather than the current month
  • CMPYEAR - the year to compare to, rather than the current year

Examples of use

Wikipedia's current date is ۲۰۲۶-۱۲-۰۳.

  • "{{age for infant|۲۰۲۶|۱۱|۲}}" می‌دهد "&&&&&&&&&&&&&031۱ ماه ۱ روز

" [۱]

  • {{age for infant|۲۰۲۶|1|1|abbr=yes}} gives: &&&&&&&&&&&&0336۱۱ ماه ۲ روز
  • "{{age for infant|۲۰۲۴|۱۱|۲}}" می‌دهد "&&&&&&&&&&&&0761۲ سال ۱ ماه

" [۲]

  • "{{age for infant|2021|1|1}}" می‌دهد "&&&&&&&&&&&02162۵ سال

" [۳]

More examples of output:

Age
&&&&&&&&&&&06911۱۸ سال
&&&&&&&&&&&06901۱۸ سال
&&&&&&&&&&&06891۱۸ سال
&&&&&&&&&&&06880۱۸ سال
&&&&&&&&&&&06870۱۸ سال
&&&&&&&&&&&06860۱۸ سال
&&&&&&&&&&&06851۱۸ سال
&&&&&&&&&&&06851۱۸ سال
&&&&&&&&&&&06841۱۸ سال
&&&&&&&&&&&07217۱۹ سال
&&&&&&&&&&&07125۱۹ سال
&&&&&&&&&&&07450۲۰ سال
&&&&&&&&&&&07784۲۱ سال
&&&&&&&&&&&07146۱۹ سال
&&&&&&&&&&&07166۱۹ سال
&&&&&&&&&&&07187۱۹ سال
&&&&&&&&&&011590۳۱ سال
&&&&&&&&&&011945۳۲ سال
&&&&&&&&&&012300۳۳ سال