Actions

Template

Difference between revisions of "Month"

From Sonic Retro

(Created page with "<includeonly>{{#ifeq:{{#pos:{{{1|}}}|-}}|4 |{{#sub:{{{1}}}|4|2}} |00 }}</includeonly><noinclude> This template converts dates written in the format YYYY-MM-DD to MM. If the da...")
 
m
Line 1: Line 1:
 
<includeonly>{{#ifeq:{{#pos:{{{1|}}}|-}}|4
 
<includeonly>{{#ifeq:{{#pos:{{{1|}}}|-}}|4
|{{#sub:{{{1}}}|4|2}}
+
|{{#sub:{{{1}}}|5|2}}
 
|00
 
|00
 
}}</includeonly><noinclude>
 
}}</includeonly><noinclude>

Revision as of 22:04, 16 June 2015

This template converts dates written in the format YYYY-MM-DD to MM. If the date is invalid or contains no month, it will return 00 as the month.