Difference between revisions of "Template:JulianWeekday"

From blackwiki
Jump to navigation Jump to search
imported>Dbenbenn
(convert to use {{#switch}})
imported>Verdy p
m
Line 1: Line 1:
{{#switch: {{#expr: {{{1}}} mod 7}}
+
<includeonly>{{#switch:{{#expr:({{{1}}})mod 7}}|0=Monday|1=Tuesday|2=Wednesday|3=Thursday|4=Friday|5=Saturday|6=Sunday|{{{1}}}}}</includeonly><noinclude>
|0=Monday
+
----
|1=Tuesday
+
{{Template documentation}}
|2=Wednesday
 
|3=Thursday
 
|4=Friday
 
|5=Saturday
 
|6=Sunday
 
}}<noinclude>
 
  
{{JulianWeekday|{{JD}}}}
+
Returns the English name of the day of week for the given julian timestamp. For example the current weekday name is <nowiki>{{JulianWeekday|{{JD}}}}</nowiki> = "{{JulianWeekday|{{JD}}}}".
 +
 
 +
; Syntax<nowiki>:</nowiki>
 +
: <tt><nowiki>{{</nowiki>{{PAGENAME}}<nowiki>|</nowiki></tt>''timestamp''<tt><nowiki>}}</nowiki></tt>
 +
* The timestamp may be any valid numeric expression that is evaluated and rounded to the nearest integer (noon) before being interpreted as a julian day number.
 +
 
 +
; See also<nowiki>:</nowiki>
 +
* [[Template:JD]]
 +
 
 +
[[Category:Date math]]
 
[[Category:Templates using ParserFunctions|{{PAGENAME}}]]
 
[[Category:Templates using ParserFunctions|{{PAGENAME}}]]
[[Category:Date math]]</noinclude>
+
 
 +
[[fr:Modèle:WEEKDAYNAME]]
 +
</noinclude>

Revision as of 21:34, 29 April 2006


Template:Template documentation

Returns the English name of the day of week for the given julian timestamp. For example the current weekday name is {{JulianWeekday|{{JD}}}} = "Thursday".

Syntax:
{{JulianWeekday|timestamp}}
  • The timestamp may be any valid numeric expression that is evaluated and rounded to the nearest integer (noon) before being interpreted as a julian day number.
See also:

fr:Modèle:WEEKDAYNAME