Difference between revisions of "Template:Calendar"
From Nookipedia, the Animal Crossing wiki
(Calendar will now default generate for the current month as opposed to January. Previous month's dates will be darkened. Will work on darkening following month's dates tomorrow.) |
(Shading the following month's dates was easier than I thought, actually. Just need to add code so shading matches during other seasons.) |
||
Line 54: | Line 54: | ||
{{!-}} | {{!-}} | ||
{{!}} height{{=}}100px style{{=}}"padding: 0 5px 0 0; vertical-align: bottom; text-align: right; border:1px solid #{{ColorSecondary}}; background-color:#f2fbfb; {{roundy|5px}};" {{!}} {{#ifeq: {{#time:l|{{{month|{{CURRENTMONTHNAME}}}}} 30 {{{year|{{LOCALYEAR}}}}}}} | Sunday | 30 | {{#ifeq: {{#time:l|{{{month|{{CURRENTMONTHNAME}}}}} 31 {{{year|{{LOCALYEAR}}}}}}} | Sunday | 31}}}} | {{!}} height{{=}}100px style{{=}}"padding: 0 5px 0 0; vertical-align: bottom; text-align: right; border:1px solid #{{ColorSecondary}}; background-color:#f2fbfb; {{roundy|5px}};" {{!}} {{#ifeq: {{#time:l|{{{month|{{CURRENTMONTHNAME}}}}} 30 {{{year|{{LOCALYEAR}}}}}}} | Sunday | 30 | {{#ifeq: {{#time:l|{{{month|{{CURRENTMONTHNAME}}}}} 31 {{{year|{{LOCALYEAR}}}}}}} | Sunday | 31}}}} | ||
− | {{!}} height{{=}}100px style{{=}}"padding: 0 5px 0 0; vertical-align: bottom; text-align: right; border:1px solid #{{ColorSecondary}}; background-color:#f2fbfb; {{roundy|5px}};" {{!}} {{#ifeq: {{#time:l|{{{month|{{CURRENTMONTHNAME}}}}} 31 {{{year|{{LOCALYEAR}}}}}}} | Monday | 31 | {{#ifeq: {{#time:l| {{#ifeq: {{{month|{{CURRENTMONTHNAME}}}}} | December | January | {{#time:F|{{#expr: {{#time:n|{{{month|{{CURRENTMONTHNAME}}}}}}} + 1}}/01}}}} 01 {{#ifeq: {{{month|{{CURRENTMONTHNAME}}}}} | December | {{#expr: {{{year|{{LOCALYEAR}}}}} + 1}} | {{{year|{{LOCALYEAR}}}}}}}}} | Monday | {{Colorshow|{{ColorSecondary}}|01}}}}}} | + | {{!}} height{{=}}100px style{{=}}"padding: 0 5px 0 0; vertical-align: bottom; text-align: right; border:1px solid #{{ColorSecondary}}; background-color:#{{#if: {{#ifeq: {{#time:l| {{#ifeq: {{{month|{{CURRENTMONTHNAME}}}}} | December | January | {{#time:F|{{#expr: {{#time:n|{{{month|{{CURRENTMONTHNAME}}}}}}} + 1}}/01}}}} 01 {{#ifeq: {{{month|{{CURRENTMONTHNAME}}}}} | December | {{#expr: {{{year|{{LOCALYEAR}}}}} + 1}} | {{{year|{{LOCALYEAR}}}}}}}}} | Monday | {{Colorshow|{{ColorSecondary}}|01}}}} | b8e9e9 | f2fbfb}}; {{roundy|5px}};" {{!}} {{#ifeq: {{#time:l|{{{month|{{CURRENTMONTHNAME}}}}} 31 {{{year|{{LOCALYEAR}}}}}}} | Monday | 31 | {{#ifeq: {{#time:l| {{#ifeq: {{{month|{{CURRENTMONTHNAME}}}}} | December | January | {{#time:F|{{#expr: {{#time:n|{{{month|{{CURRENTMONTHNAME}}}}}}} + 1}}/01}}}} 01 {{#ifeq: {{{month|{{CURRENTMONTHNAME}}}}} | December | {{#expr: {{{year|{{LOCALYEAR}}}}} + 1}} | {{{year|{{LOCALYEAR}}}}}}}}} | Monday | {{Colorshow|{{ColorSecondary}}|01}}}}}} |
− | {{!}} height{{=}}100px style{{=}}"padding: 0 5px 0 0; vertical-align: bottom; text-align: right; border:1px solid #{{ColorSecondary}}; background-color:# | + | {{!}} height{{=}}100px style{{=}}"padding: 0 5px 0 0; vertical-align: bottom; text-align: right; border:1px solid #{{ColorSecondary}}; background-color:#b8e9e9; {{roundy|5px}};" {{!}} {{#ifeq: {{#time:l| |
{{#ifeq: {{{month|{{CURRENTMONTHNAME}}}}} | December | January | {{#time:F|{{#expr: {{#time:n|{{{month|{{CURRENTMONTHNAME}}}}}}} + 1}}/01}}}} 01 {{#ifeq: {{{month|{{CURRENTMONTHNAME}}}}} | December | {{#expr: {{{year|{{LOCALYEAR}}}}} + 1}} | {{{year|{{LOCALYEAR}}}}}}}}} | Tuesday | {{Colorshow|{{ColorSecondary}}|01}} | {{#ifeq: {{#time:l| {{#ifeq: {{{month|{{CURRENTMONTHNAME}}}}} | December | January | {{#time:F|{{#expr: {{#time:n|{{{month|{{CURRENTMONTHNAME}}}}}}} + 1}}/01}}}} 02 {{#ifeq: {{{month|{{CURRENTMONTHNAME}}}}} | December | {{#expr: {{{year|{{LOCALYEAR}}}}} + 1}} | {{{year|{{LOCALYEAR}}}}}}}}} | Tuesday | {{Colorshow|{{ColorSecondary}}|02}}}}}} | {{#ifeq: {{{month|{{CURRENTMONTHNAME}}}}} | December | January | {{#time:F|{{#expr: {{#time:n|{{{month|{{CURRENTMONTHNAME}}}}}}} + 1}}/01}}}} 01 {{#ifeq: {{{month|{{CURRENTMONTHNAME}}}}} | December | {{#expr: {{{year|{{LOCALYEAR}}}}} + 1}} | {{{year|{{LOCALYEAR}}}}}}}}} | Tuesday | {{Colorshow|{{ColorSecondary}}|01}} | {{#ifeq: {{#time:l| {{#ifeq: {{{month|{{CURRENTMONTHNAME}}}}} | December | January | {{#time:F|{{#expr: {{#time:n|{{{month|{{CURRENTMONTHNAME}}}}}}} + 1}}/01}}}} 02 {{#ifeq: {{{month|{{CURRENTMONTHNAME}}}}} | December | {{#expr: {{{year|{{LOCALYEAR}}}}} + 1}} | {{{year|{{LOCALYEAR}}}}}}}}} | Tuesday | {{Colorshow|{{ColorSecondary}}|02}}}}}} | ||
− | {{!}} height{{=}}100px style{{=}}"padding: 0 5px 0 0; vertical-align: bottom; text-align: right; border:1px solid #{{ColorSecondary}}; background-color:# | + | {{!}} height{{=}}100px style{{=}}"padding: 0 5px 0 0; vertical-align: bottom; text-align: right; border:1px solid #{{ColorSecondary}}; background-color:#b8e9e9; {{roundy|5px}};" {{!}} {{#ifeq: {{#time:l| |
{{#ifeq: {{{month|{{CURRENTMONTHNAME}}}}} | December | January | {{#time:F|{{#expr: {{#time:n|{{{month|{{CURRENTMONTHNAME}}}}}}} + 1}}/01}}}} 02 {{#ifeq: {{{month|{{CURRENTMONTHNAME}}}}} | December | {{#expr: {{{year|{{LOCALYEAR}}}}} + 1}} | {{{year|{{LOCALYEAR}}}}}}}}} | Wednesday | {{Colorshow|{{ColorSecondary}}|02}} | {{#ifeq: {{#time:l| {{#ifeq: {{{month|{{CURRENTMONTHNAME}}}}} | December | January | {{#time:F|{{#expr: {{#time:n|{{{month|{{CURRENTMONTHNAME}}}}}}} + 1}}/01}}}} 03 {{#ifeq: {{{month|{{CURRENTMONTHNAME}}}}} | December | {{#expr: {{{year|{{LOCALYEAR}}}}} + 1}} | {{{year|{{LOCALYEAR}}}}}}}}} | Wednesday | {{Colorshow|{{ColorSecondary}}|03}}}}}} | {{#ifeq: {{{month|{{CURRENTMONTHNAME}}}}} | December | January | {{#time:F|{{#expr: {{#time:n|{{{month|{{CURRENTMONTHNAME}}}}}}} + 1}}/01}}}} 02 {{#ifeq: {{{month|{{CURRENTMONTHNAME}}}}} | December | {{#expr: {{{year|{{LOCALYEAR}}}}} + 1}} | {{{year|{{LOCALYEAR}}}}}}}}} | Wednesday | {{Colorshow|{{ColorSecondary}}|02}} | {{#ifeq: {{#time:l| {{#ifeq: {{{month|{{CURRENTMONTHNAME}}}}} | December | January | {{#time:F|{{#expr: {{#time:n|{{{month|{{CURRENTMONTHNAME}}}}}}} + 1}}/01}}}} 03 {{#ifeq: {{{month|{{CURRENTMONTHNAME}}}}} | December | {{#expr: {{{year|{{LOCALYEAR}}}}} + 1}} | {{{year|{{LOCALYEAR}}}}}}}}} | Wednesday | {{Colorshow|{{ColorSecondary}}|03}}}}}} | ||
− | {{!}} height{{=}}100px style{{=}}"padding: 0 5px 0 0; vertical-align: bottom; text-align: right; border:1px solid #{{ColorSecondary}}; background-color:# | + | {{!}} height{{=}}100px style{{=}}"padding: 0 5px 0 0; vertical-align: bottom; text-align: right; border:1px solid #{{ColorSecondary}}; background-color:#b8e9e9; {{roundy|5px}};" {{!}} {{#ifeq: {{#time:l| |
{{#ifeq: {{{month|{{CURRENTMONTHNAME}}}}} | December | January | {{#time:F|{{#expr: {{#time:n|{{{month|{{CURRENTMONTHNAME}}}}}}} + 1}}/01}}}} 03 {{#ifeq: {{{month|{{CURRENTMONTHNAME}}}}} | December | {{#expr: {{{year|{{LOCALYEAR}}}}} + 1}} | {{{year|{{LOCALYEAR}}}}}}}}} | Thursday | {{Colorshow|{{ColorSecondary}}|03}} | {{#ifeq: {{#time:l| {{#ifeq: {{{month|{{CURRENTMONTHNAME}}}}} | December | January | {{#time:F|{{#expr: {{#time:n|{{{month|{{CURRENTMONTHNAME}}}}}}} + 1}}/01}}}} 04 {{#ifeq: {{{month|{{CURRENTMONTHNAME}}}}} | December | {{#expr: {{{year|{{LOCALYEAR}}}}} + 1}} | {{{year|{{LOCALYEAR}}}}}}}}} | Thursday | {{Colorshow|{{ColorSecondary}}|04}}}}}} | {{#ifeq: {{{month|{{CURRENTMONTHNAME}}}}} | December | January | {{#time:F|{{#expr: {{#time:n|{{{month|{{CURRENTMONTHNAME}}}}}}} + 1}}/01}}}} 03 {{#ifeq: {{{month|{{CURRENTMONTHNAME}}}}} | December | {{#expr: {{{year|{{LOCALYEAR}}}}} + 1}} | {{{year|{{LOCALYEAR}}}}}}}}} | Thursday | {{Colorshow|{{ColorSecondary}}|03}} | {{#ifeq: {{#time:l| {{#ifeq: {{{month|{{CURRENTMONTHNAME}}}}} | December | January | {{#time:F|{{#expr: {{#time:n|{{{month|{{CURRENTMONTHNAME}}}}}}} + 1}}/01}}}} 04 {{#ifeq: {{{month|{{CURRENTMONTHNAME}}}}} | December | {{#expr: {{{year|{{LOCALYEAR}}}}} + 1}} | {{{year|{{LOCALYEAR}}}}}}}}} | Thursday | {{Colorshow|{{ColorSecondary}}|04}}}}}} | ||
− | {{!}} height{{=}}100px style{{=}}"padding: 0 5px 0 0; vertical-align: bottom; text-align: right; border:1px solid #{{ColorSecondary}}; background-color:# | + | {{!}} height{{=}}100px style{{=}}"padding: 0 5px 0 0; vertical-align: bottom; text-align: right; border:1px solid #{{ColorSecondary}}; background-color:#b8e9e9; {{roundy|5px}};" {{!}} {{#ifeq: {{#time:l| |
{{#ifeq: {{{month|{{CURRENTMONTHNAME}}}}} | December | January | {{#time:F|{{#expr: {{#time:n|{{{month|{{CURRENTMONTHNAME}}}}}}} + 1}}/01}}}} 04 {{#ifeq: {{{month|{{CURRENTMONTHNAME}}}}} | December | {{#expr: {{{year|{{LOCALYEAR}}}}} + 1}} | {{{year|{{LOCALYEAR}}}}}}}}} | Friday | {{Colorshow|{{ColorSecondary}}|04}} | {{#ifeq: {{#time:l| {{#ifeq: {{{month|{{CURRENTMONTHNAME}}}}} | December | January | {{#time:F|{{#expr: {{#time:n|{{{month|{{CURRENTMONTHNAME}}}}}}} + 1}}/01}}}} 05 {{#ifeq: {{{month|{{CURRENTMONTHNAME}}}}} | December | {{#expr: {{{year|{{LOCALYEAR}}}}} + 1}} | {{{year|{{LOCALYEAR}}}}}}}}} | Friday | {{Colorshow|{{ColorSecondary}}|05}}}}}} | {{#ifeq: {{{month|{{CURRENTMONTHNAME}}}}} | December | January | {{#time:F|{{#expr: {{#time:n|{{{month|{{CURRENTMONTHNAME}}}}}}} + 1}}/01}}}} 04 {{#ifeq: {{{month|{{CURRENTMONTHNAME}}}}} | December | {{#expr: {{{year|{{LOCALYEAR}}}}} + 1}} | {{{year|{{LOCALYEAR}}}}}}}}} | Friday | {{Colorshow|{{ColorSecondary}}|04}} | {{#ifeq: {{#time:l| {{#ifeq: {{{month|{{CURRENTMONTHNAME}}}}} | December | January | {{#time:F|{{#expr: {{#time:n|{{{month|{{CURRENTMONTHNAME}}}}}}} + 1}}/01}}}} 05 {{#ifeq: {{{month|{{CURRENTMONTHNAME}}}}} | December | {{#expr: {{{year|{{LOCALYEAR}}}}} + 1}} | {{{year|{{LOCALYEAR}}}}}}}}} | Friday | {{Colorshow|{{ColorSecondary}}|05}}}}}} | ||
− | {{!}} height{{=}}100px style{{=}}"padding: 0 5px 0 0; vertical-align: bottom; text-align: right; border:1px solid #{{ColorSecondary}}; background-color:# | + | {{!}} height{{=}}100px style{{=}}"padding: 0 5px 0 0; vertical-align: bottom; text-align: right; border:1px solid #{{ColorSecondary}}; background-color:#b8e9e9; {{roundy|5px}};" {{!}} {{#ifeq: {{#time:l| |
{{#ifeq: {{{month|{{CURRENTMONTHNAME}}}}} | December | January | {{#time:F|{{#expr: {{#time:n|{{{month|{{CURRENTMONTHNAME}}}}}}} + 1}}/01}}}} 05 {{#ifeq: {{{month|{{CURRENTMONTHNAME}}}}} | December | {{#expr: {{{year|{{LOCALYEAR}}}}} + 1}} | {{{year|{{LOCALYEAR}}}}}}}}} | Saturday | {{Colorshow|{{ColorSecondary}}|05}} | {{#ifeq: {{#time:l| {{#ifeq: {{{month|{{CURRENTMONTHNAME}}}}} | December | January | {{#time:F|{{#expr: {{#time:n|{{{month|{{CURRENTMONTHNAME}}}}}}} + 1}}/01}}}} 06 {{#ifeq: {{{month|{{CURRENTMONTHNAME}}}}} | December | {{#expr: {{{year|{{LOCALYEAR}}}}} + 1}} | {{{year|{{LOCALYEAR}}}}}}}}} | Saturday | {{Colorshow|{{ColorSecondary}}|06}}}}}}}} | {{#ifeq: {{{month|{{CURRENTMONTHNAME}}}}} | December | January | {{#time:F|{{#expr: {{#time:n|{{{month|{{CURRENTMONTHNAME}}}}}}} + 1}}/01}}}} 05 {{#ifeq: {{{month|{{CURRENTMONTHNAME}}}}} | December | {{#expr: {{{year|{{LOCALYEAR}}}}} + 1}} | {{{year|{{LOCALYEAR}}}}}}}}} | Saturday | {{Colorshow|{{ColorSecondary}}|05}} | {{#ifeq: {{#time:l| {{#ifeq: {{{month|{{CURRENTMONTHNAME}}}}} | December | January | {{#time:F|{{#expr: {{#time:n|{{{month|{{CURRENTMONTHNAME}}}}}}} + 1}}/01}}}} 06 {{#ifeq: {{{month|{{CURRENTMONTHNAME}}}}} | December | {{#expr: {{{year|{{LOCALYEAR}}}}} + 1}} | {{{year|{{LOCALYEAR}}}}}}}}} | Saturday | {{Colorshow|{{ColorSecondary}}|06}}}}}}}} | ||
|}<noinclude><br> | |}<noinclude><br> |
Revision as of 01:48, August 15, 2015
April 2024 | ||||||
---|---|---|---|---|---|---|
Sunday | Monday | Tuesday | Wednesday | Thursday | Friday | Saturday |
24 | 01 | 02 | 03 | 04 | 05 | 06 |
07 | 08 | 09 | 10 | 11 | 12 | 13 |
14 | 15 | 16 | 17 | 18 | 19 | 20 |
21 | 22 | 23 | 24 | 25 | 26 | 27 |
28 | 29 | 30 | 31 | 02 | 03 | 04 |
Syntax
{{Calendar | month = (calendar month to be generated - optional) | year = (corresponding year calendar month is to be generated for - optional) }}
Notes
- If no month is entered, the template will generate a calendar for the current month.
- If no year is entered, the template will generate a calendar for the current year.