Difference between revisions of "Template:Monthoffset"
(New page: <!-- Check if less than one -->{{#ifeq:{{#expr:({{CURRENTDAY}}+{{{1}}})<1}}|1<!-- Do if less than one -->|{{MONTHNAME|{{#expr:{{CURRENTMONTH}}-1}}}}<!-- Check if more than days in month --...) |
(<noinclude>Category:Calendar templates</noinclude>) |
||
| Line 30: | Line 30: | ||
|} | |} | ||
</noinclude> | </noinclude> | ||
| + | <noinclude>[[Category:Calendar templates|Monthoffset]]</noinclude> | ||
Latest revision as of 06:15, April 9, 2008
February
Documentation
This template calculates the month that will result from a given positive or negative offset in days. See also {{dayoffset}} to calculate the day of the month.
Examples:
| English | Template | Result |
|---|---|---|
| Today - 30 | {{monthoffset|-30}} | January |
| Today + 2 | {{monthoffset|2}} | February |
| Today + 30 | {{monthoffset|30}} | February |
Combination with {{dayoffset}}:
| English | Template | Result |
|---|---|---|
| Today - 30 | {{monthoffset|-30}} {{dayoffset|-30}} | January
18
|
| Today + 2 | {{monthoffset|2}} {{dayoffset|2}} | February
19
|
| Today + 30 | {{monthoffset|30}} {{dayoffset|30}} | February
19
|