Template:FA

From Homestar Runner Wiki

(Difference between revisions)
Jump to: navigation, search
(change date so that there will always be an example that spans two months)
(return the correct year if the first week would cause problems)
Line 1: Line 1:
-
<includeonly>{{#setvar:featured-article-date|{{#time:Y-m-d|{{{1|today}}} - {{#expr:{{#time:N|{{{1|today}}}}}-1}} days}}}}{{#setvar:featured-article-week|{{#expr:{{#time:W|{{#var:featured-article-date}}}}}}}}{{#time:[["HRWiki:Featured article for" Y, "week" {{#var:featured-article-week}}]] (M j"&ndash;"|{{#var:featured-article-date}}}}{{#ifeq:{{#time:M|{{#var:featured-article-date}}}}|{{#time:M|{{#var:featured-article-date}} + 6 days}}|{{#time:j|{{#var:featured-article-date}} + 6 days}}|{{#time:M j|{{#var:featured-article-date}} + 6 days}}}})</includeonly><noinclude>Returns the featured article of the current week or for the specified date. The specified date does not have to be the first day of the week.
+
<includeonly>{{#setvar:featured-article-date|{{#time:Y-m-d|{{{1|today}}} - {{#expr:{{#time:N|{{{1|today}}}}}-1}} days}}}}{{#setvar:featured-article-week|{{#expr:{{#time:W|{{#var:featured-article-date}}}}}}}}{{#time:[["HRWiki:Featured article for" o, "week" {{#var:featured-article-week}}]] (M j"&ndash;"|{{#var:featured-article-date}}}}{{#ifeq:{{#time:M|{{#var:featured-article-date}}}}|{{#time:M|{{#var:featured-article-date}} + 6 days}}|{{#time:j|{{#var:featured-article-date}} + 6 days}}|{{#time:M j|{{#var:featured-article-date}} + 6 days}}}})</includeonly><noinclude>Returns the featured article of the current week or for the specified date. The specified date does not have to be the first day of the week.
==Usage==
==Usage==

Revision as of 23:31, 16 June 2010

Returns the featured article of the current week or for the specified date. The specified date does not have to be the first day of the week.

Usage