Difference between revisions of "Template:Years ago"

From Conservapedia
Jump to navigation Jump to search
(Various historical events)
m (Protected "Template:Years ago" [edit=sysop:move=sysop])
 
(5 intermediate revisions by one other user not shown)
Line 1: Line 1:
−
{{#expr: {{CURRENTYEAR}} - {{{1}}} }}<noinclude>
+
<includeonly>{{#expr: {{CURRENTYEAR}} - {{{1}}} }}</includeonly><noinclude>
 +
 
 +
==Code==
 +
 
 +
Subtract the argument from the current year:
 +
 
 +
<nowiki>{{#expr: {{CURRENTYEAR}} - {{{1}}} }}</nowiki>
 +
 
 +
==Examples==
  
−
Examples:
 
 
* <nowiki>{{years ago|1980}}</nowiki> = {{years ago|1980}} (years since Reagan was elected)
 
* <nowiki>{{years ago|1980}}</nowiki> = {{years ago|1980}} (years since Reagan was elected)
  
Line 8: Line 15:
 
|+ Various historical events
 
|+ Various historical events
 
|-
 
|-
−
|Year || Event || Years ago
+
!Year || Event || Years ago
 
|-
 
|-
 +
|1602
 
|Shakespeare wrote ''[[Hamlet]]''  
 
|Shakespeare wrote ''[[Hamlet]]''  
−
|1602
 
 
|{{years ago|1601}}
 
|{{years ago|1601}}
 
|-
 
|-

Latest revision as of 09:59, July 26, 2007


Code

Subtract the argument from the current year:

{{#expr: {{CURRENTYEAR}} - {{{1}}} }}

Examples

  • {{years ago|1980}} = 46 (years since Reagan was elected)


Various historical events
Year Event Years ago
1602 Shakespeare wrote Hamlet 425
1945 US and allies won WWII 81