Difference between revisions of "Template:JD"
Jump to navigation
Jump to search
imported>Verdy p m |
imported>Verdy p m |
||
| Line 3: | Line 3: | ||
( ({{{1}}}) *12+ ({{{2|1}}}) round 0)>18994 or | ( ({{{1}}}) *12+ ({{{2|1}}}) round 0)>18994 or | ||
( ({{{1}}}) *12+ ({{{2|1}}}) round 0)=18994 and ({{{3|1}}}) >=15 | ( ({{{1}}}) *12+ ({{{2|1}}}) round 0)=18994 and ({{{3|1}}}) >=15 | ||
| − | |G{{JD/Gregorian|{{{1}}}|{{{2|1}}}|{{{3|1}}}|{{{4|}}}|{{{5|}}}|{{{6|}}}}} | + | |G{{JD/Gregorian|{{{1}}}|{{{2|1}}}|{{{3|1}}}|{{{4|12}}}|{{{5|0}}}|{{{6|0}}}}} |
| − | |J{{JD/Julian |{{{1}}}|{{{2|1}}}|{{{3|1}}}|{{{4|}}}|{{{5|}}}|{{{6|}}}}}}} | + | |J{{JD/Julian |{{{1}}}|{{{2|1}}}|{{{3|1}}}|{{{4|12}}}|{{{5|0}}}|{{{6|0}}}}}}} |
|{{JD/Gregorian|{{CURRENTYEAR}}|{{CURRENTMONTH}}|{{CURRENTDAY2}}|{{CURRENTHOUR}}|{{CURRENTMINUTE}}}} | |{{JD/Gregorian|{{CURRENTYEAR}}|{{CURRENTMONTH}}|{{CURRENTDAY2}}|{{CURRENTHOUR}}|{{CURRENTMINUTE}}}} | ||
}}</includeonly><noinclude>{{Template documentation}} | }}</includeonly><noinclude>{{Template documentation}} | ||
Revision as of 08:11, 30 April 2006
Template:Template documentation
This template converts date elements, or date and time elements, into a Julian date timestamp. It interprets all dates starting at 15 October 1582 in the Gregorian calendar, otherwise it uses the Julian calendar that was valid until 04 October 1582.
- Syntax:
- {{JD|year|[month]|[day]|[hour]|[minute]|[second]}}
- {{JD}}
- If the year parameter is missing, all other parameters are ignored, and their default is the current UTC date and time, as set on the server.
- Otherwise, all parameters for the date and time must be specified as valid numeric expressions.
- The default day and month are 1.
- The computed year and month parameters are first converted into a rounded number of months since 01 December 1 AD and then converted to the actual year and month. For this prior computing, the day parameter is ignored.
- The default hour is 12 (for noon).
- The default minute or second is 0.
- Any date whose actual month and year are before October 1582, or are October 1582 but the computed day parameter is before the 15th at noon, will be interpreted as dates in the Julian calendar.
- Example:
- It is JD 2461053.8277778 now.
- {{JD|1582|10|15|11|59|59}} returns G2299160.9999884.
- {{JD|1582|10|15}} returns G2299161.
- See also: