Difference between revisions of "Template:DSFL Year/Test"
Jump to navigation
Jump to search
37thchamber (talk | contribs) |
37thchamber (talk | contribs) m |
||
Line 1: | Line 1: | ||
{{#switch: {{{2}}} | {{#switch: {{{2}}} | ||
<!-- Different output based on second argument passed --> | <!-- Different output based on second argument passed --> | ||
− | |year = [[DSFL season {{{1}}}|{{#if:{{{ | + | |year = [[DSFL season {{{1}}}|{{#if:{{{linktext|}}}|{{{linktext}}}|{{#expr:2015+{{#if:{{{1|}}}|{{{1}}}|1}}}}}} {{#if:{{{s|}}} = yes|(S{{{1}}})}}]] <!-- displays as the corresponding year --> |
− | |full = [[DSFL season {{{1}}}|{{#if:{{{ | + | |full = [[DSFL season {{{1}}}|{{#if:{{{linktext|}}}|{{{linktext}}}|{{#expr:2015+{{#if:{{{1|}}}|{{{1}}}|1}}}} DSFL season}}]] <!-- displays as the corresponding year --> |
<!-- draft links --> | <!-- draft links --> | ||
|draft-full = [[Season {{{1}}} DSFL Draft|{{#if:{{{3|}}}|{{{3}}}|{{#expr:2015+{{#if:{{{1|}}}|{{{1}}}|1}}}} DSFL Draft}}]] <!-- displays as "XXXX DSFL draft" --> | |draft-full = [[Season {{{1}}} DSFL Draft|{{#if:{{{3|}}}|{{{3}}}|{{#expr:2015+{{#if:{{{1|}}}|{{{1}}}|1}}}} DSFL Draft}}]] <!-- displays as "XXXX DSFL draft" --> | ||
Line 42: | Line 42: | ||
|nolink = {{#expr:2015+{{#if:{{{1|}}}|{{{1}}}|1}}}} | |nolink = {{#expr:2015+{{#if:{{{1|}}}|{{{1}}}|1}}}} | ||
<!-- default value goes to DSFL season page, link displays as year --> | <!-- default value goes to DSFL season page, link displays as year --> | ||
− | |#default = [[DSFL season {{{1}}}|{{#expr:2015+{{#if:{{{1|}}}|{{{1}}}|1}}}}]] | + | |#default = [[DSFL season {{{1}}}|{{#expr:2015+{{#if:{{{1|}}}|{{{1}}}|1}}}} {{#if:{{{s|}}} = yes| (S{{{1}}})}}]] |
}}<noinclude> | }}<noinclude> | ||
+ | |||
+ | This version allows you to add "s=yes" as a parameter to show the season number in brackets after the year. | ||
+ | |||
<nowiki>{{DSFL Year/Test|4|s=yes}}</nowiki> results in {{DSFL Year/Test|4|s=yes}} | <nowiki>{{DSFL Year/Test|4|s=yes}}</nowiki> results in {{DSFL Year/Test|4|s=yes}} | ||
+ | |||
+ | <nowiki>{{DSFL Year/Test|4|year|s=yes}}</nowiki> results in {{DSFL Year/Test|4|year|s=yes}} | ||
[[Category:Date Shortcuts]]</noinclude> | [[Category:Date Shortcuts]]</noinclude> |