Difference between revisions of "Template talk:History"
From OCE Space Simulation
(One intermediate revision by one other user not shown) | |||
Line 3: | Line 3: | ||
==Magic Words== | ==Magic Words== | ||
I'm using the magic word <nowiki>{{PAGENAME}}</nowiki> here, which returns the name of the current page. [[User:Stefanido|Stefanido]] 12:26, 2 March 2010 (EST) | I'm using the magic word <nowiki>{{PAGENAME}}</nowiki> here, which returns the name of the current page. [[User:Stefanido|Stefanido]] 12:26, 2 March 2010 (EST) | ||
+ | :Nice, was thinking of that. D'you like the italics? It looked a bit boring in all bold.[[User:Q-Cumber|Q-Cumber]] 16:58, 2 March 2010 (EST) | ||
+ | ==Trying to make this better== | ||
+ | <nowiki> | ||
+ | curryear={{#expr {{#sub:{{PAGENAME}}|1|4}}}} | ||
+ | twodig={{#expr{{#sub:{{PAGENAME}}|6|2}}}} | ||
+ | |||
+ | preyear={{#expr curryear-1}} | ||
+ | pretwodig={{#expr twodig-1}} | ||
+ | Prev=preyear-pretwodig | ||
+ | |||
+ | postyear={{#expr curryear+1}} | ||
+ | posttwodig={{#expr twodig+1}} | ||
+ | Post=postyear-posttwodig | ||
+ | </nowiki> |
Latest revision as of 16:58, 2 March 2010
No hurt feelings; I should've done it that way from the start. Thanks. Stefanido 17:26, 1 March 2010 (EST)
Magic Words
I'm using the magic word {{PAGENAME}} here, which returns the name of the current page. Stefanido 12:26, 2 March 2010 (EST)
- Nice, was thinking of that. D'you like the italics? It looked a bit boring in all bold.Q-Cumber 16:58, 2 March 2010 (EST)
Trying to make this better
curryear={{#expr {{#sub:{{PAGENAME}}|1|4}}}} twodig={{#expr{{#sub:{{PAGENAME}}|6|2}}}} preyear={{#expr curryear-1}} pretwodig={{#expr twodig-1}} Prev=preyear-pretwodig postyear={{#expr curryear+1}} posttwodig={{#expr twodig+1}} Post=postyear-posttwodig