Template:Timeline test: Difference between revisions

From Tardis Wiki, the free Doctor Who reference
(Created page with '<noinclude>{{Documentation}}</noinclude> <includeonly> {| class="browser" |- | class="prev"|[[{{{1|{{#expr:{{PAGENAME}}-1}}}}}]] | class="topic"|[[{{nth|{{#expr:(({{PAGENAME…')
 
m (Changed protection level for "Template:Timeline test": Robot: Protecting all pages from category Template sandbox (‎[edit=autoconfirmed] (indefinite) ‎[move=sysop] (indefinite)))
 
(11 intermediate revisions by 2 users not shown)
Line 1: Line 1:
<noinclude>{{Documentation}}</noinclude>
<noinclude>{{Documentation}}</noinclude>
<includeonly>
<includeonly><!--
{| class="browser"
 
|-
 
| class="prev"|[[{{{1|{{#expr:{{PAGENAME}}-1}}}}}]]
Tests for the last four letters of the word "century" in the PAGENAME.  If it finds them, it calls for the CenturyNav template.  If it doesn't, it returns the value of -1 and nothing happens.
| class="topic"|[[{{nth|{{#expr:(({{PAGENAME}}-({{PAGENAME}} mod 100))/100)+1}}}} century]]<br />[[{{#expr: {{PAGENAME}} - ({{PAGENAME}} mod 10)}}s]]
 
| class="next"|[[{{{2|{{#expr:{{PAGENAME}}+1}}}}}]]
 
|}
-->{{#ifeq:{{#rpos:{{PAGENAME}}|tury}}
<noinclude>{{timeline test}}</noinclude>
|-1
<includeonly>
|
</includeonly>
|{{CenturyNav}}
<includeonly>
}}<!--
[[Category:Template sandbox]]</includeonly>
 
 
Tests for the string "0s" in the title of a time-related page.  Of these types of pages, only decade pages contain the alphanumeric combination "0s".  This part of the template will obviously wreak havoc on non-time related pages.  If it finds "0s", it will call the DecadeNav template. If it doesn't, it returns the value of -1 and nothing happens.
 
 
-->{{#ifeq:{{#rpos:{{PAGENAME}}|0s}}
|-1
|
| {{DecadeNav}}
}}<!--
 
 
Tests for the number 1 as the result of dividing the PAGENAME by itself.  Only year pages will result in a perfect 1 with this expression.  If the calculation results in 1, Bob's your uncle — the YearNav template is called.  If it doesn't, nothing happens.
 
-->{{#ifeq:{{#expr:{{PAGENAME}}/{{PAGENAME}}}}
|1
|{{YearNav}}
|
}}</includeonly><noinclude>{{timeline test}}[[Category:Template sandbox]]</noinclude>

Latest revision as of 03:16, 19 May 2013

Instructions for {{Timeline test}}