Difference between revisions of "Template:Age"

From IntactiWiki
Jump to navigation Jump to search
(taken from https://wiki.mises.org/mediawiki/index.php?title=Template:Age)
 
m (added description)
Line 1: Line 1:
<includeonly>{{#expr:({{{4|{{CURRENTYEAR}}}}})-({{{1}}})-(({{{5|{{CURRENTMONTH}}}}})<({{{2}}})or({{{5|{{CURRENTMONTH}}}}})=({{{2}}})and({{{6|{{CURRENTDAY}}}}})<({{{3}}}))}}</includeonly>
+
<includeonly>{{#expr:({{{4|{{CURRENTYEAR}}}}})-({{{1}}})-(({{{5|{{CURRENTMONTH}}}}})<({{{2}}})or({{{5|{{CURRENTMONTH}}}}})=({{{2}}})and({{{6|{{CURRENTDAY}}}}})<({{{3}}}))}}</includeonly><noinclude>
 +
== Usage ==
 +
Call the template with the birth date of birth (format yyyy|mm|dd) and the date of death=.
 +
<nowiki>{{Age|yyyy|mm|dd|yyyy|mm|dd}}</nowiki>
 +
 
 +
== Example ==
 +
<nowiki>[[Jonathon Conte]] died at age {{Age|1981|06|14|2016|05|09}}.</nowiki>
 +
 
 +
[[Jonathon Conte]] died at age {{Age|1981|06|14|2016|05|09}}.
 +
</noinclude>

Revision as of 12:52, 26 July 2021

Usage

Call the template with the birth date of birth (format yyyy|mm|dd) and the date of death=.

{{Age|yyyy|mm|dd|yyyy|mm|dd}}

Example

[[Jonathon Conte]] died at age {{Age|1981|06|14|2016|05|09}}.

Jonathon Conte died at age 34.