Template:Start date: Difference between revisions

From Wiki Maui Linux NET
Jump to navigation Jump to search
Created page with "<includeonly> <span class="startdate" style="white-space:nowrap;"> {{{1|}}}{{#if:{{{2|}}}|-{{{2}}}{{#if:{{{3|}}}|-{{{3}}}}}}} </span> </includeonly><noinclude> '''Usage:''' * <code>{{Start date|YYYY}}</code> → displays just the year * <code>{{Start date|YYYY|MM}}</code> → displays year and month * <code>{{Start date|YYYY|MM|DD}}</code> → full date (YYYY-MM-DD) Optionally, you can use the <code>df</code> parameter for day-first formatting: * <code>{{Start date|YYYY..."
 
No edit summary
 
Line 1: Line 1:
<includeonly>
<includeonly>
<span class="startdate" style="white-space:nowrap;">
<span class="startdate" style="white-space:nowrap;">
{{{1|}}}{{#if:{{{2|}}}|-{{{2}}}{{#if:{{{3|}}}|-{{{3}}}}}}}
{{{1|}}}{{{2|}}}{{{3|}}}
</span>
</span>
</includeonly><noinclude>
</includeonly><noinclude>
'''Usage:'''
'''Usage:'''
* <code>{{Start date|YYYY}}</code> → displays just the year
* <code>{{Start date|YYYY}}</code> → displays year
* <code>{{Start date|YYYY|MM}}</code> → displays year and month
* <code>{{Start date|YYYY|MM}}</code> → displays year and month
* <code>{{Start date|YYYY|MM|DD}}</code> → full date (YYYY-MM-DD)
* <code>{{Start date|YYYY|MM|DD}}</code> → displays full date (continuous, no separators)


Optionally, you can use the <code>df</code> parameter for day-first formatting:
This simplified version does not require ParserFunctions and will print all provided arguments in order.
* <code>{{Start date|YYYY|MM|DD|df=yes}}</code> → DD-MM-YYYY (visual only)
 
The output is a simple machine-readable and visually minimal date string.
</noinclude>
</noinclude>

Latest revision as of 12:50, 20 October 2025

Usage:

YYYY → displays year

YYYYMM → displays year and month

YYYYMMDD → displays full date (continuous, no separators)

This simplified version does not require ParserFunctions and will print all provided arguments in order.