Template:Start date: Difference between revisions

Al Piskun (talk | contribs)
Created page with "<includeonly>{{#if:{{{3|}}}|{{{1}}}-{{#if:{{{2|}}}|{{padleft:{{{2}}}|2|0}}-{{padleft:{{{3}}}|2|0}}|{{padleft:{{{2}}}|2|0}}}}|{{#if:{{{2|}}}|{{{1}}}-{{padleft:{{{2}}}|2|0}}|{{{1}}}}}}}}</includeonly><noinclude> == Template:Start date == Formats a date for use in infoboxes, particularly the '''release date''' or '''start date''' field. Outputs a clean date string in YYYY-MM-DD format. === Usage === <pre>{{Start date|YYYY|MM|DD}}</pre> === Parameters === {| class="wikitab..."
 
Al Piskun (talk | contribs)
No edit summary
 
Line 1: Line 1:
<includeonly>{{#if:{{{3|}}}|{{{1}}}-{{#if:{{{2|}}}|{{padleft:{{{2}}}|2|0}}-{{padleft:{{{3}}}|2|0}}|{{padleft:{{{2}}}|2|0}}}}|{{#if:{{{2|}}}|{{{1}}}-{{padleft:{{{2}}}|2|0}}|{{{1}}}}}}}}</includeonly><noinclude>
<includeonly>{{#if:{{{3|}}}|{{{1}}}-{{padleft:{{{2}}}|2|0}}-{{padleft:{{{3}}}|2|0}}|{{#if:{{{2|}}}|{{{1}}}-{{padleft:{{{2}}}|2|0}}|{{{1}}}}}}}</includeonly><noinclude>
== Template:Start date ==
== Template:Start date ==
Formats a date for use in infoboxes, particularly the '''release date''' or '''start date''' field. Outputs a clean date string in YYYY-MM-DD format.
Formats a date for use in infoboxes, particularly the '''release date''' or '''start date''' field. Outputs a clean date string in YYYY-MM-DD format.
Line 27: Line 27:
| <code><nowiki>{{Start date|2021}}</nowiki></code> || 2021
| <code><nowiki>{{Start date|2021}}</nowiki></code> || 2021
|}
|}
=== Notes ===
* Used in <code>{{[[Template:Infobox software|Infobox software]]}}</code> for the <code>released</code> field.
* On large wikis like Wikipedia this template also embeds hidden microformat markup; this version outputs plain text only, which is suitable for most private or small wikis.


[[Category:Formatting templates]]
[[Category:Formatting templates]]
[[Category:Date templates]]
[[Category:Date templates]]
</noinclude>
</noinclude>