Changes

Jump to navigation Jump to search
updates, formatting
{{Documentation subpage}}
<!-- Place categories where indicated at the bottom of this page and interwikis at Wikidata -->
{{Template shortcut|d-da}}
[[File:BadSalzdetfurthBadenburgerStr060529.jpg|right|80px]]

{{tl|Death-date and age}} displays a person's date of death and age at that date. Besides calculating the age at death, the benefit of using this template is to allow for the inclusion of hidden [[microformat]] dates, which may be indexed or searched by software tools.

Note: The template may not calculate the age at death correctly if full dates (month, day, year) are not provided. For example, a person who was born in 1941 and died in 1993 could have been either 51 or 52 on the day of their death, depending on whether they had reached their birthday in their death year:
: <code><nowiki>{{Death-date and age|</nowiki>1993|1941}}</code> → {{Death-date and age|1993|1941}}
: <code><nowiki>{{Death-date and age|</nowiki>May 1993|May 1941}}</code> → {{Death-date and age|May 1993|May 1941}}
When only the years are known, consider using {{tl|Death year and age}} instead:
: <code><nowiki>{{Death year and age|</nowiki>1993|1941}}</code> → {{Death year and age|1993|1941}}
: <code><nowiki>{{Death year and age|</nowiki>1993|1941|5}}</code> → {{Death year and age|1993|1941|5}}

== Usage ==
; Format:
: <code><nowiki>{{Death-date and age| death date | birth date }}</nowiki></code>
: <code><nowiki>{{Death-date and age| death date | birth date | death date display form with links, templates etc. }}</nowiki></code>

== Examples ==
{| width="100%" xclass="toccolours" style="margin-top:.5em; border:1px solid #a0a0a0; background-color:#f8f8ff;" <!-- no class formatting other than article space -->
|+ '''<span style="font-size:110%;">Examples of {{tl|Death-date and age}}</span>''' ''(colors for emphasis only)''
|- style="text-align:left; line-height:1.4em;"
| style="white-space:normal;" | '''Month first format: Sample below displays <span style="color:#038945;">{{Death-date and age|February 24, 1993|April 12, 1941}}</span>, with invisible microformat dtend date:''' ''1993-02-25''
: <code><nowiki>{{Death-date and age|</nowiki><span style="color:#705000;">''<nowiki>February 24, 1993|April 12, 1941</nowiki>''</span>}}</code>
|- style="text-align:left; line-height:1.4em;"
| style="white-space:normal;" | '''Day first format: Sample below displays <span style="color:#038945;">{{Death-date and age| 24 February 1993 | 12 April 1941 }}</span>, with invisible microformat dtend date:''' ''1993-02-25''
: <code><nowiki>{{Death-date and age| 24 February 1993 | 12 April 1941 </nowiki>}}</code>
|- style="text-align:left; line-height:1.4em;"
| style="white-space:normal;" | '''Year only, year and month only: Sample below displays <span style="color:#038945;">{{Death-date and age| 1993 | 1941 }}</span>, with invisible microformat dtend date: '''''1994''
: <code><nowiki>{{Death-date and age| 1993 | 1941 </nowiki>}}</code>
|- style="text-align:left; line-height:1.4em;"
| style="white-space:normal;" | '''Julian dates demo. Sample below displays <span style="color:#038945;">{{Death-date and age| 30 May 1672 | 15 May 1623 | gregorian=9 June 1672 }}</span>, with invisible microformat dtend date:''' ''1692-06-10''
: <code><nowiki>{{Death-date and age| 30 May 1672 | 15 May 1623 |</nowiki><span style="color:#705000;"> '''gregorian=9 June 1672''' </span>}}</code>
|- style="text-align:left; line-height:1.4em;"
| style="white-space:normal;" | '''Extreme dates: Birth date is BC, death date AD Sample below displays <span style="color:#038945;">{{Death-date and age| 0014-08-19 | 0063-09-23 | bce=b | August 19, AD 14 }}</span>, with invisible microformat dtend date:''' ''0014-08-20''
: <code><nowiki>{{Death-date and age| 0014-08-19 | 0063-09-23 |</nowiki><span style="color:#705000;"> '''bce=b''' | August 19, </span><nowiki>AD 14</nowiki> }}</code>
|}

== Parameters ==
: <code><nowiki>{{Death-date and age|</nowiki>''death date''|''birth date''|''additional parameters''}}</code>

{| class="wikitable" style="font-size:95%;"
! colspan="3" style="padding-left:64px;text-align:left;" | Parameter !! Default
|-
| width="60" style="vertical-align:top;" | (required) || width="120" style="vertical-align:top; text-align:center;" | 1 || Death date. May be year only, year and month, year month and day, expressed in natural formats: e.g.: 24 August 1953, 1955-08-25, Sunday, December 7, 1941. If parameter three is not specified, the death date is displayed in exactly this format. This value as well as parameter 2 may not include links. If links or templates that do not evaluate as recognizable dates are desired, use parameter 3. || style="vertical-align:top; text-align:center;" | –
|-
| width="60" style="vertical-align:top;" | (required) || width="120" style="vertical-align:top; text-align:center;" | 2 || Birth date. For accurate results, if year and month only was specified for death date, year and month should be specified for birth date (that is, the degree of precision should be in agreement). Julian dates may be used, but both Death and Birth dates '''must''' be on the same calendar. || style="vertical-align:top; text-align:center;" | –
|-
| width="60" style="vertical-align:top;" | (optional) || width="120" style="vertical-align:top; text-align:center;" | 3 || The death date to display. This may include links or templates, or any combination of them, and overrides parameter 1. || style="vertical-align:top; text-align:center;" | parm 1
|-
| style="vertical-align:top;" | (optional) || style="vertical-align:top; text-align:center;" | bce || If birth date is BC, set to "''b''". If birth and death date are BC, set to "''bd''" or "''d''". || style="vertical-align:top; text-align:center;" | –
|-
| style="vertical-align:top;" | (optional) || style="vertical-align:top; text-align:center;" | gregorian || If Julian dates are used, this parameter is required. The date provided is used for emitting the correct microformat translation of the death date. || style="vertical-align:top; text-align:center;" | parm 1
|-
| style="vertical-align:top;" | (optional) || style="vertical-align:top; text-align:center;" | dt || This value if present is the [[ISO8601]] value emitted to indicate microformat death (dtend) date. It overrides any calculated value. || style="vertical-align:top; text-align:center;" | –
|}

== Unusual dates ==

=== Julian dates ===
This template emits data in hidden [[microformat]] form. Technically, the requirement of this format is that all dates throughout time be expressed in the same calendar (the [[ISO8601]] standard specifies this as gregorian), so [[julian calendar]] format dates cannot properly be used for this purpose. Proper emission of this invisible metadata requires that a [[gregorian calendar]] form be provided, even though properly speaking, gregorian dates did not exist prior to 1582. If accuracy of emission with microformats is a concern, the parameters death date and birth date that are displayed in the article may be provided in julian, and the correct gregorian death date form is provided in the "gregorian" parameter. Several calculators [http://www.fourmilab.ch/documents/calendar/#juliancalendar] that convert from Julian to Gregorian are available and are listed in the Julian calendar article. Example: Pope Adrian VI [[Special:PermanentLink/276562220]]:
: <nowiki>{{death-date and age| September 14, 1523 | March 2, 1459 | gregorian= September 24, 1523}} </nowiki>
There are some rare circumstances where system limitations do not permit correct handling of a few dates. These should have no impact on correct age calculation except in extremely unusual circumstances. When these errors create incorrect microformat data, use the dt parameter.
* some dates that would be valid in a non-Gregorian context are treated as out-of-range dates and converted to the next-best in-range values. For example, <code><nowiki>{{date|30 February 1712}}</nowiki></code> results in <code>{{date|30 February 1712}}</code> because – even though 30 February 1712 is a valid date in the Swedish calendar – February 1712 had only 29 days in the Gregorian calendar.
** ten dates are not reformatted. These are 29 February & 1 March of the years 1000, 1100, 1300, 1400, 1500. The cause of this is the same as that of the Swedish 30 February 1712.

=== Dates with years less than 3 digits ===
Some dates with less than three digits will not be recognized. In these cases, use YYYY-MM-DD format for both death and birth dates. Use Parameter 3 to display the death date in the desired format. It is permitted to specify just Year or Year and month only.

== See also ==
* [[Wikipedia:Age calculation templates]]

{{Birth, death and age templates}}

<includeonly>{{sandbox other||
<!-- Categories below this line; interwikis at Wikidata -->
[[Category:Date mathematics templates|Death date and age]]
[[Category:Templates generating microformat date and age|{{BASEPAGENAME}}]]
}}</includeonly>
Anonymous user

Navigation menu