Difference between revisions of "Template:Weekdays in month"

From Geohashing
imported>Tjtrumpet2323
m
imported>Tjtrumpet2323
m
Line 1: Line 1:
<includeonly>{{#ifexpr: {{#expr: 29 + ( 7 + {{{3}}} - {{weekday|{{{1}}}|{{{2}}}|1}} ) mod 7 }} > {{#time:t|{{{year}}}-{{{month}}}-01}}</includeonly><noinclude>
+
<includeonly>{{#ifexpr: {{#expr: 29 + ( 7 + {{{3}}} - {{weekday|{{{1}}}|{{{2}}}|1}} ) mod 7 }} > {{#time:t|{{{year}}}-{{{month}}}-01}} | 4 | 5}}</includeonly><noinclude>
 
<nowiki>{{Weekdays in month|Y|M|N}}</nowiki> returns how many days N (0=Sunday, ... 6=Saturday) there are in month M of year Y.
 
<nowiki>{{Weekdays in month|Y|M|N}}</nowiki> returns how many days N (0=Sunday, ... 6=Saturday) there are in month M of year Y.
  

Revision as of 20:03, 6 June 2008

{{Weekdays in month|Y|M|N}} returns how many days N (0=Sunday, ... 6=Saturday) there are in month M of year Y.


« November 2024 »
Su Mo Tu We Th Fr Sa
1 2
3 4 5 6 7 8 9
10 11 12 13 14 15 16
17 18 19 20 21 22 23
24 25 26 27 28 29 30

This month has the following counts for the different days:

  • Mondays: 4
  • Tuesdays: 4
  • Wednesdays: 4
  • Thursdays: 4
  • Fridays: 5
  • Saturdays: 5
  • Sundays: 4

See also