Help:Link Templates

From Card Hunter Wiki
(Difference between revisions)
Jump to: navigation, search
(Created page with "You can use templates to create inline text links to common types of pages. In most cases, it's a lot less typing! <br>For instance to link to the page for '''Spiked Shield''...")
 
(cleaning up table and making it prettier)
Line 11: Line 11:
  
 
{| class="wikitable"
 
{| class="wikitable"
! To link to: !! Use: !! Result:
+
! style="width: 12%" | To link to:
 +
! style="width: 34%" | Use:
 +
! style="width: 54%" | Result:
 
|-
 
|-
 
! rowspan="2" | Cards
 
! rowspan="2" | Cards
| align="center" | <pre>{{Cards|xxxxxx}}</pre>
+
| align="center" | <code><nowiki>{{Cards|xxxxxx}}</nowiki></code>
''or''
+
''or''<br>
<pre>{{C|xxxxxx}}</pre>
+
<code><nowiki>{{C|xxxxxx}}</nowiki></code>
 
| A link to the page 'Cards/xxxxxx' that reads as "xxxxxx"
 
| A link to the page 'Cards/xxxxxx' that reads as "xxxxxx"
''Ex: ''<code><nowiki>{{C|Bash}}</nowiki></code>'' gives ''{{C|Bash}}
+
''Example: ''<code><nowiki>{{C|Bash}}</nowiki></code>'' gives ''{{C|Bash}}
 
|-
 
|-
| align="center" | <pre>{{Cards|xxxxxx|other text}}</pre>
+
| align="center" | <code><nowiki>{{Cards|xxxxxx|other text}}</nowiki></code>
''or''
+
''or''<br>
<pre>{{C|xxxxxx|other text}}</pre>
+
<code><nowiki>{{C|xxxxxx|other text}}</nowiki></code>
 
| A link to the page 'Cards/xxxxxx' that reads as "other text"
 
| A link to the page 'Cards/xxxxxx' that reads as "other text"
''Ex: ''<code><nowiki>{{C|Arcing Zap|strange card}}</nowiki></code>'' gives ''{{C|Arcing Zap|strange card}}
+
''Example: ''<code><nowiki>{{C|Arcing Zap|strange card}}</nowiki></code>'' gives ''{{C|Arcing Zap|strange card}}
 
|-
 
|-
 
! rowspan="2" | Items
 
! rowspan="2" | Items
| align="center" | <pre>{{Items|xxxxxx}}</pre>
+
| align="center" | <code><nowiki>{{Items|xxxxxx}}</nowiki></code>
''or''
+
''or''<br>
<pre>{{I|xxxxxx}}</pre>
+
<code><nowiki>{{I|xxxxxx}}</nowiki></code>
 
| A link to the page 'Items/xxxxxx' that reads as "xxxxxx"
 
| A link to the page 'Items/xxxxxx' that reads as "xxxxxx"
''Ex: ''<code><nowiki>{{I|Cloth Cap}}</nowiki></code>'' gives ''{{I|Cloth Cap}}
+
''Example: ''<code><nowiki>{{I|Cloth Cap}}</nowiki></code>'' gives ''{{I|Cloth Cap}}
 
|-
 
|-
| align="center" | <pre>{{Items|xxxxxx|other text}}</pre>
+
| align="center" | <code><nowiki>{{Items|xxxxxx|other text}}</nowiki></code>
''or''
+
''or''<br>
<pre>{{I|xxxxxx|other text}}</pre>
+
<code><nowiki>{{I|xxxxxx|other text}}</nowiki></code>
 
| A link to the page 'Items/xxxxxx' that reads as "other text"
 
| A link to the page 'Items/xxxxxx' that reads as "other text"
''Ex: ''<code><nowiki>{{I|Copper Axe|sharp!}}</nowiki></code>'' gives ''{{I|Copper Axe|sharp!}}
+
''Example: ''<code><nowiki>{{I|Copper Axe|sharp!}}</nowiki></code>'' gives ''{{I|Copper Axe|sharp!}}
 
|-
 
|-
 
! rowspan="2" | Keywords
 
! rowspan="2" | Keywords
| align="center" | <pre>{{Keywords|xxxxxx}}</pre>
+
| align="center" | <code><nowiki>{{Keywords|xxxxxx}}</nowiki></code>
''or''
+
''or''<br>
<pre>{{K|xxxxxx}}</pre>
+
<code><nowiki>{{K|xxxxxx}}</nowiki></code>
 
| A link to the page 'Keywords/xxxxxx' that reads as "xxxxxx"
 
| A link to the page 'Keywords/xxxxxx' that reads as "xxxxxx"
''Ex: ''<code><nowiki>{{K|Holy}}</nowiki></code>'' gives ''{{K|Holy}}
+
''Example: ''<code><nowiki>{{K|Holy}}</nowiki></code>'' gives ''{{K|Holy}}
 
|-
 
|-
| align="center" | <pre>{{Keywords|xxxxxx|other text}}</pre>
+
| align="center" | <code><nowiki>{{Keywords|xxxxxx|other text}}</nowiki></code>
''or''
+
''or''<br>
<pre>{{KW|xxxxxx|other text}}</pre>
+
<code><nowiki>{{K|xxxxxx|other text}}</nowiki></code>
 
| A link to the page 'Keywords/xxxxxx' that reads as "other text"
 
| A link to the page 'Keywords/xxxxxx' that reads as "other text"
''Ex: ''<code><nowiki>{{K|Poison|Poison 2}}</nowiki></code>'' gives ''{{K|Poison|Poison 2}}
+
''Example: ''<code><nowiki>{{K|Poison|Poison 2}}</nowiki></code>'' gives ''{{K|Poison|Poison 2}}
 +
|-
 +
! colspan="3" | Important! Capital letters count when making links. {{C|Bash}} is not the same as {{C|bash}}.<br>
 +
{{K|Teleport|Teleport 3}} is not the same as {{K|teLEPorT|Teleport 3}} (Mouse over to check the link!)
 
|}
 
|}

Revision as of 15:28, 22 October 2012

You can use templates to create inline text links to common types of pages. In most cases, it's a lot less typing!
For instance to link to the page for Spiked Shield, I could type
[[Items/Spiked Shield|Spiked Shield]]
or I could type
{{I|Spiked Shield}}
Both options have the result Spiked Shield. Which one do you think is faster?

Table of Link Templates

The following table demonstrates how to use Card Hunter Wiki's link templates:


To link to: Use: Result:
Cards {{Cards|xxxxxx}}

or
{{C|xxxxxx}}

A link to the page 'Cards/xxxxxx' that reads as "xxxxxx"

Example: {{C|Bash}} gives Bash

{{Cards|xxxxxx|other text}}

or
{{C|xxxxxx|other text}}

A link to the page 'Cards/xxxxxx' that reads as "other text"

Example: {{C|Arcing Zap|strange card}} gives strange card

Items {{Items|xxxxxx}}

or
{{I|xxxxxx}}

A link to the page 'Items/xxxxxx' that reads as "xxxxxx"

Example: {{I|Cloth Cap}} gives Cloth Cap

{{Items|xxxxxx|other text}}

or
{{I|xxxxxx|other text}}

A link to the page 'Items/xxxxxx' that reads as "other text"

Example: {{I|Copper Axe|sharp!}} gives sharp!

Keywords {{Keywords|xxxxxx}}

or
{{K|xxxxxx}}

A link to the page 'Keywords/xxxxxx' that reads as "xxxxxx"

Example: {{K|Holy}} gives Holy

{{Keywords|xxxxxx|other text}}

or
{{K|xxxxxx|other text}}

A link to the page 'Keywords/xxxxxx' that reads as "other text"

Example: {{K|Poison|Poison 2}} gives Poison 2

Important! Capital letters count when making links. Bash is not the same as bash.

Teleport 3 is not the same as Teleport 3 (Mouse over to check the link!)

      
Personal tools
Namespaces

Variants
Views
Actions
Navigation
Tools