Difference between revisions of "Template:Countdown/sandbox"

From Detective Conan Wiki
(Reverted to Bobo's template)
m (Added timeDiff variable (hopefully works))
Line 1: Line 1:
 
<includeonly><div class="countdown-container">
 
<includeonly><div class="countdown-container">
{{#ifeq:  
+
{{#vardefine:timeDiff | {{#expr: {{#time:U|{{{1}}}}} - {{#time:U}} }} }}
  {{#expr: ceil(({{#time:U|{{{1}}}}} - {{#time:U}}) / 86400)}} | -0 | <big>  
+
 
  {{orange|'''TODAY!!!'''}}</big> |  
+
{{#ifeq: {{#expr: ceil(({{timeDiff}}) / 86400)}} | -0 |  
      {{#ifeq:  
+
    <big>{{orange|'''TODAY!!!'''}}</big> |  
        {{#expr: ceil(({{#time:U|{{{1}}}}} - {{#time:U}}) / 86400)}} | 1 |  
+
    {{#ifeq: {{#expr: ceil(({{timeDiff}}) / 86400)}} | 1 |  
        '''{{#expr: ceil(({{#time:U|{{{1}}}}} - {{#time:U}}) / 86400)}}''' day |  
+
        '''{{#expr: ceil(({{timeDiff}}) / 86400)}}''' day |  
        '''{{#expr: ceil(({{#time:U|{{{1}}}}} - {{#time:U}}) / 86400)}}''' days }} }}
+
        '''{{#expr: ceil(({{timeDiff}}) / 86400)}}''' days }} }}
 
</div></includeonly>
 
</div></includeonly>

Revision as of 21:34, 26 December 2024