Template:Birthday: Difference between revisions

From Inkipedia, the Splatoon wiki
(Reorder so that </br> is after noinclude.)
m (Text replacement - "{{ userbox" to "{{Userbox")
 
(5 intermediate revisions by 5 users not shown)
Line 1: Line 1:
{{ userbox
{{Userbox
| border-c = #088A08
| border-c = #088A08
| id      = 🎂
| id      = 🎂
Line 9: Line 9:
     {{#expr: ceil({{#expr: {{#time:U|{{{1|28-09}}}-{{CURRENTYEAR}}}} - {{#time:U}}}}/60/60/24)}}
     {{#expr: ceil({{#expr: {{#time:U|{{{1|28-09}}}-{{CURRENTYEAR}}}} - {{#time:U}}}}/60/60/24)}}
     | 0 |
     | 0 |
     Happy birthday to '''{{ROOTPAGENAME}}'''! |
     Happy birthday to '''{{ROOTPAGENAME}}'''! |  
     {{#ifeq:  
     This user has {{{2|{{Gender}}}}} birthday in {{#ifeq:  
        {{#expr: ceil({{#expr: {{#time:U|{{{1|28-09}}}-{{CURRENTYEAR}}}} - {{#time:U}}}}/60/60/24)<0}} | 1 | This user has {{{2|their}}} birthday in '''{{#expr: ceil({{#expr: {{#time:U|{{{1|28-09}}}-{{#expr:{{CURRENTYEAR}}+1}}}} - {{#time:U}}}}/60/60/24)}} days'''. | This user has {{{2|their}}} birthday in '''{{#expr: ceil({{#expr: {{#time:U|{{{1|28-09}}}-{{CURRENTYEAR}}}} - {{#time:U}}}}/60/60/24)}} days'''.}}
        {{#expr: ceil({{#expr: {{#time:U|{{{1|28-09}}}-{{CURRENTYEAR}}}} - {{#time:U}}}}/60/60/24)<0}} | 1 | '''{{#expr: ceil({{#expr: {{#time:U|{{{1|28-09}}}-{{#expr:{{CURRENTYEAR}}+1}}}} - {{#time:U}}}}/60/60/24)}} days'''. | '''{{#expr: ceil({{#expr: {{#time:U|{{{1|28-09}}}-{{CURRENTYEAR}}}} - {{#time:U}}}}/60/60/24)}} days'''.}}
     }}
     }}
}}
}}
Line 19: Line 19:
</br>
</br>
== Usage ==
== Usage ==
  <nowiki>{{Birthday|<date>-<month>|<possessive pronoun>}}</nowiki>
  <nowiki>{{Birthday|<date>-<month>|<optional: possessive pronoun>}}</nowiki>
If <possessive pronoun> is not provided, the template will use the pronoun picked in [[Special:Preferences#ooui-php-28|the user's preferences]].
 
=== Example ===
=== Example ===
  <nowiki>{{Birthday|13-8|her}}</nowiki>
  <nowiki>{{Birthday|13-8|her}}</nowiki>
{{Birthday|13-8|her}}
{{Birthday|13-8|her}}
[[Category:User boxes]]</noinclude>
[[Category:User boxes]]</noinclude>

Latest revision as of 13:01, 29 June 2023

🎂This user has their birthday in 147 days.




Usage

{{Birthday|<date>-<month>|<optional: possessive pronoun>}}

If <possessive pronoun> is not provided, the template will use the pronoun picked in the user's preferences.

Example

{{Birthday|13-8|her}}
🎂This user has her birthday in 101 days.