Difference between revisions of "Template:User Wiki age"

From Team Fortress Wiki
Jump to: navigation, search
(Let us test)
m (Undo edit by Tiagoquix (Talk) (3265648) // Partially undo)
(Tag: Undo)
 
(23 intermediate revisions by 11 users not shown)
Line 1: Line 1:
 
{{userbox
 
{{userbox
| border-c = #8B4500
+
| border-c = #000000
| id      = {{#expr:{{CURRENTYEAR}}-{{{year|2011}}}-{{#ifexpr:{{CURRENTMONTH}}>{{{month|03}}}
+
| id      = [[File:Dead Heat Icon.png|40px]]
  |0
+
| id-c    = #f5e5c1
  |{{#ifexpr:{{CURRENTMONTH}}<{{{month|02}}}
 
  |1
 
  |{{#ifexpr:{{CURRENTDAY}}>={{{day|12}}}
 
    |0
 
    |1
 
  }}
 
  }}
 
}}}}
 
| id-c    = #E99B42
 
 
| id-fc    = #fff
 
| id-fc    = #fff
 
| id-s    = 15
 
| id-s    = 15
| info    = <small>''As of {{CURRENTMONTHNAME}} {{CURRENTDAY}}, {{CURRENTYEAR}},''<br /></small>I have been a [[Main_Page|TF2 Wikipedian]] for <!--
+
| info    = <small>''As of {{CURRENTDAY}} {{CURRENTMONTHNAME}}, {{CURRENTYEAR}},''<br /></small>I have been a [[Team Fortress Wiki|Team Fortress Wiki member]] for {{#invoke:Age|age_ymd|{{{year|2011}}}|{{{month|2}}}|{{{day|12}}}}} (since {{{day}}} <noinclude>{{{month}}}</noinclude>{{#switch: {{{month}}}
//-->{{#expr:{{CURRENTYEAR}}-{{{year|2011}}}-{{#ifexpr:{{CURRENTMONTH}}>{{{month|03}}}
+
|1=January
  |0
+
|2=February
  |{{#ifexpr:{{CURRENTMONTH}}<{{{month|02}}}
+
|3=March
  |1
+
|4=April
  |{{#ifexpr:{{CURRENTDAY}}>={{{day|12}}}
+
|5=May
    |0
+
|6=June
    |1
+
|7=July
  }}
+
|8=August
  }}
+
|9=September
}}}} {{#ifexpr: {{CURRENTYEAR}} != 1 | years, | year,}}<!--
+
|10=October
//-->{{#expr:{{CURRENTMONTH}}-{{{month|2}}}+{{#ifexpr:{{CURRENTDAY}}>={{{day|12}}}
+
|11=November
  |{{#ifexpr:{{CURRENTMONTH}}>={{{month|2}}}
+
|12=December
  |0
+
|01=January
  |12
+
|02=February
  }}
+
|03=March
  |{{#ifexpr:{{CURRENTMONTH}}>{{{month|2}}}
+
|04=April
  |-1
+
|05=May
  |11
+
|06=June
  }}
+
|07=July
}}}} <!--
+
|08=August
//-->{{#ifexpr: {{CURRENTYEAR}} != 1 | months, | month,}} <!--
+
|09=September}}, {{{year}}}).
//-->{{#expr:{{CURRENTDAY}}-{{{day|12}}}+{{#ifexpr:{{CURRENTDAY}}>={{{day|12}}}
 
  |0
 
  |{{#switch:{{CURRENTMONTH}}
 
  |5|7|10|12=30
 
  |1|2|4|6|8|9|11=31
 
  |3={{#ifexpr:{{CURRENTYEAR}} mod 4=0
 
    |29
 
    |28
 
  }}
 
  }}
 
}}}} {{#ifexpr: {{CURRENTYEAR}} != 1 | days. | day.}}
 
 
| info-c  = #EECFA1
 
| info-c  = #EECFA1
 
| info-p  = 2px 4px
 
| info-p  = 2px 4px
Line 52: Line 32:
  
 
<noinclude>
 
<noinclude>
 +
{{Lua|Age}}
 
{{doc begin}}
 
{{doc begin}}
 
__TOC__
 
__TOC__
Line 65: Line 46:
 
! <nowiki>{{User Wiki age|year=2011|month=02|day=12}}</nowiki>
 
! <nowiki>{{User Wiki age|year=2011|month=02|day=12}}</nowiki>
 
| {{User Wiki age|year=2011|month=02|day=12}}
 
| {{User Wiki age|year=2011|month=02|day=12}}
|-
 
! <nowiki>{{User Wiki age|year=2011|month=02|day=12|link=true}}</nowiki>
 
| {{User Wiki age|year=2011|month=02|day=12|link=true}}
 
|-
 
! <nowiki>{{User Wiki age|day=12|month=02|year=2011|link=true}}</nowiki>
 
| {{User Wiki age|day=12|month=02|year=2011|link=true}}
 
 
|}
 
|}
  
 
[[Category:Userbox templates|Wiki age]]</noinclude>
 
[[Category:Userbox templates|Wiki age]]</noinclude>

Latest revision as of 10:31, 26 September 2022

Dead Heat Icon.png As of 1 May, 2024,
I have been a Team Fortress Wiki member for 13 years, 2 months, 17 days (since {{{day}}} {{{month}}}, {{{year}}}).


Documentation for User Wiki age

Usage

Sample code Resulting infobox
{{User Wiki age|day=12|month=02|year=2011}}
Dead Heat Icon.png As of 1 May, 2024,
I have been a Team Fortress Wiki member for 13 years, 2 months, 17 days (since 12 February, 2011).


{{User Wiki age|year=2011|month=02|day=12}}
Dead Heat Icon.png As of 1 May, 2024,
I have been a Team Fortress Wiki member for 13 years, 2 months, 17 days (since 12 February, 2011).