Template:Patch name: Difference between revisions
From Valheim Wiki
Created page with "<includeonly>{{#ifeq: {{{sort|}}} | yes |<span style="display:none">{{#time:Y-m-d|{{{1|}}}-{{{2|}}}-{{{3|}}}}}</span>}}{{#ifeq: {{{date-only|}}} | yes | {{dictionary/common st..." |
No edit summary |
||
| (10 intermediate revisions by the same user not shown) | |||
| Line 1: | Line 1: | ||
<includeonly>{{#ifeq: {{{sort|}}} | yes |<span style="display:none">{{#time:Y-m-d|{{{1|}}}-{{{2|}}}-{{{3|}}}}}</span>}}{{#ifeq: {{{date-only|}}} | yes | {{dictionary/common strings/date-fmt|2={{{2|}}}|3={{{3|}}}|4={{{1|}}}}} | <includeonly>{{#ifeq: {{{sort|}}} | yes |<span style="display:none">{{#time:Y-m-d|{{{1|}}}-{{{2|}}}-{{{3|}}}}}</span>}}{{#ifeq: {{{date-only|}}} | yes | {{dictionary/common strings/date-fmt|2={{{2|}}}|3={{{3|}}}|4={{{1|}}}}} | ||
|{{#ifeq: {{{no-link|}}} | yes | |{{#ifeq: {{{no-link|}}} | yes | ||
| {{dictionary/common strings/patch-{{{4|default}}}-fmt|1={{{ | | {{dictionary/common strings/patch-{{{4|default}}}-fmt|1={{{1|2021}}}|2={{{2|12}}}|3={{{3|31}}}|{{#if:{{{lang|}}}|lang|null}}={{{lang|{{{force|}}}}}}}} | ||
| [[{{{link|{{lang date|force=en|1={{{2}}}}} {{{3}}}, {{{1}}} Patch | | [[{{{link|{{lang date|force=en|1={{{2}}}}} {{{3}}}, {{{1}}} Patch}}}|{{dictionary/common strings/patch-{{#ifeq: {{{date|}}}|true|date-}}{{{4|default}}}-fmt|1={{{1|2021}}}|2={{{2|12}}}|3={{{3|31}}}|{{#if:{{{lang|}}}|lang|null}}={{{lang|{{{force|}}}}}}}}]] | ||
}}}}</includeonly><noinclude> | }}}}</includeonly><noinclude> | ||
Dates should be inputted in YYYY-MM-DD format with leading zeros (e.g. {{tlx|patch name|year|month|day}}, {{tlx| | Dates should be inputted in YYYY-MM-DD format with leading zeros (e.g. {{tlx|patch name|year|month|day}}, {{tlx|patch name|2021|12|09}}). | ||
=== Usage === | === Usage === | ||
* {{tlx|patch name| | * {{tlx|patch name|2021|09|16}} (where {{code|09}} is the month of September, {{code|16}} is the day and {{code|2021}} the year) produces: {{patch name|2021|09|16}} | ||
* {{tlx|patch name| | * {{tlx|patch name|2021|09|16}} on [[Page/pt-br]] would produce: {{patch name|2021|09|16|lang=pt-br}} | ||
* {{tlx|patch name| | * {{tlx|patch name|2021|09|16|5=no-link=yes}} produces: {{patch name|2021|09|16|no-link=yes}} | ||
* {{tlx|patch name| | * {{tlx|patch name|2021|09|16|5=link=Test}} produces: {{patch name|2021|09|16|link=Test}} | ||
* {{tlx|patch name| | * {{tlx|patch name|2021|09|16|5=date=true}} produces: {{patch name|2021|09|16|date=true}} (link label contains the date only) | ||
* {{tlx|patch name| | * {{tlx|patch name|2021|09|16|5=date-only=yes}} produces: {{patch name|2021|09|16|date-only=yes}} (no links to patches and label only contains the date. Useful for events not associated with patches) | ||
* {{tlx|patch name| | * {{tlx|patch name|2021|09|16|5=sort=yes}} will add an invisible string ''2021-09-16'' at the start of the result. This can be useful in sortable tables | ||
[[Category:Templates|Patch name]] | [[Category:Templates|Patch name]] | ||
</noinclude> | </noinclude> | ||
Latest revision as of 20:37, 13 December 2022
Dates should be inputted in YYYY-MM-DD format with leading zeros (e.g. {{patch name|year|month|day}}, {{patch name|2021|12|09}}).
Usage
{{patch name|2021|09|16}}(where09is the month of September,16is the day and2021the year) produces: September 16, 2021 Patch{{patch name|2021|09|16}}on Page/pt-br would produce: Atualização de 16 de September de 2021{{patch name|2021|09|16|no-link=yes}}produces: September 16, 2021 Patch{{patch name|2021|09|16|link=Test}}produces: September 16, 2021 Patch{{patch name|2021|09|16|date=true}}produces: September 16, 2021 (link label contains the date only){{patch name|2021|09|16|date-only=yes}}produces: September 16, 2021 (no links to patches and label only contains the date. Useful for events not associated with patches){{patch name|2021|09|16|sort=yes}}will add an invisible string 2021-09-16 at the start of the result. This can be useful in sortable tables