Template:Main: Difference between revisions

From Halopedia, the Halo wiki

mNo edit summary
m (So what was wrong?)
Line 1: Line 1:
:''Main article{{#if:{{{2|}}}|s}}: [[{{#if:{{{wiki|}}}|w:c:{{{wiki}}}:}}{{{1}}}|{{{l1|{{{1}}}}}}]]{{#if:{{{2| }}}
:''Main article{{#if:{{{2|}}}|s}}: {{#if:{{{wiki|}}}|{{Interwiki link|{{{1}}}|{{{wiki|}}}|{{{l1|{{{1}}}}}}}}|[[{{{1}}}|{{{l1|{{{1}}}}}}]]}}{{#if:{{{2|}}}|{{#if:{{{3|}}}|,| and}} {{#if:{{{wiki|}}}|{{Interwiki link|{{{2}}}|{{{wiki|}}}|{{{l2|{{{2}}}}}}}}|[[{{{2}}}|{{{l2|{{{2}}}}}}]]}}}}{{#if:{{{3|}}}|{{#if:{{{4|}}}|,|, and}} {{#if:{{{wiki|}}}|{{Interwiki link|{{{3}}}|{{{wiki|}}}|{{{l3|{{{3}}}}}}}}|[[{{{3}}}|{{{l3|{{{3}}}}}}]]}}}}{{#if:{{{4|}}}|{{#if:{{{5|}}}|,|, and}} {{#if:{{{wiki|}}}|{{Interwiki link|{{{4}}}|{{{wiki|}}}|{{{l4|{{{4}}}}}}}}|[[{{{4}}}|{{{l4|{{{4}}}}}}]]}}}}{{#if:{{{5|}}}|{{#if:{{{6|}}}|,|, and}} {{#if:{{{wiki|}}}|{{Interwiki link|{{{5}}}|{{{wiki|}}}|{{{l5|{{{5}}}}}}}}|[[{{{5}}}|{{{l5|{{{5}}}}}}]]}}}}{{#if:{{{6|}}}|{{#if:{{{7|}}}|,|, and}} {{#if:{{{wiki|}}}|{{Interwiki link|{{{6}}}|{{{wiki|}}}|{{{l6|{{{6}}}}}}}}|[[{{{6}}}|{{{l6|{{{6}}}}}}]]}}}}{{#if:{{{7|}}}|{{#if:{{{8|}}}|,|, and}} {{#if:{{{wiki|}}}|{{Interwiki link|{{{7}}}|{{{wiki|}}}|{{{l7|{{{7}}}}}}}}|[[{{{7}}}|{{{l7|{{{7}}}}}}]]}}}}{{#if:{{{8|}}}|{{#if:{{{9|}}}|,|, and}} {{#if:{{{wiki|}}}|{{Interwiki link|{{{8}}}|{{{wiki|}}}|{{{l8|{{{8}}}}}}}}|[[{{{8}}}|{{{l8|{{{8}}}}}}]]}}}}{{#if:{{{9|}}}|{{#if:{{{10|}}}|,|, and}} {{#if:{{{wiki|}}}|{{Interwiki link|{{{9}}}|{{{wiki|}}}|{{{l9|{{{9}}}}}}}}|[[{{{9}}}|{{{l9|{{{9}}}}}}]]}}}}{{#if:{{{10|}}}|, and {{#if:{{{wiki|}}}|{{Interwiki link|{{{10}}}|{{{wiki|}}}|{{{l10|{{{10}}}}}}}}|[[{{{10}}}|{{{l10|{{{10}}}}}}]]}}}}''{{#if:{{{11|}}}| (too many parameters in {{[[Template:main|main]]}})}}<noinclude>
|{{#if:{{{3|}}}|,&#32;|&#32;and&#32;}}[[{{#if:{{{wiki|}}}|w:c:{{{wiki}}}:}}{{{2}}}|{{{l2|{{{2}}}}}}]]}}{{#if:{{{3|}}}
|{{#if:{{{4|}}}|,&#32;|,&#32;and&#32;}}[[{{#if:{{{wiki|}}}|w:c:{{{wiki}}}:}}{{{3}}}|{{{l3|{{{3}}}}}}]]}}{{#if:{{{4|}}}
|{{#if:{{{5|}}}|,&#32;|,&#32;and&#32;}}[[{{#if:{{{wiki|}}}|w:c:{{{wiki}}}:}}{{{4}}}|{{{l4|{{{4}}}}}}]]}}{{#if:{{{5|}}}
|{{#if:{{{6|}}}|,&#32;|,&#32;and&#32;}}[[{{#if:{{{wiki|}}}|w:c:{{{wiki}}}:}}{{{5}}}|{{{l5|{{{5}}}}}}]]}}{{#if:{{{6|}}}
|{{#if:{{{7|}}}|,&#32;|,&#32;and&#32;}}[[{{#if:{{{wiki|}}}|w:c:{{{wiki}}}:}}{{{6}}}|{{{l6|{{{6}}}}}}]]}}{{#if:{{{7|}}}
|{{#if:{{{8|}}}|,&#32;|,&#32;and&#32;}}[[{{#if:{{{wiki|}}}|w:c:{{{wiki}}}:}}{{{7}}}|{{{l7|{{{7}}}}}}]]}}{{#if:{{{8|}}}
|{{#if:{{{9|}}}|,&#32;|,&#32;and&#32;}}[[{{#if:{{{wiki|}}}|w:c:{{{wiki}}}:}}{{{8}}}|{{{l8|{{{8}}}}}}]]}}{{#if:{{{9|}}}
|{{#if:{{{10|}}}|,&#32;|,&#32;and&#32;}}[[{{#if:{{{wiki|}}}|w:c:{{{wiki}}}:}}{{{9}}}|{{{l9|{{{9}}}}}}]]}}{{#if:{{{10|}}}
|, and [[{{#if:{{{wiki|}}}|w:c:{{{wiki}}}:}}{{{10}}}|{{{l10|{{{10}}}}}}]]}}''{{#if:{{{11| }}}|&#32; (too many parameters in &#123;&#123;[[Template:main|main]]&#125;&#125;)}}<noinclude>


__NOTOC__
__NOTOC__


== Usage ==
== Usage ==
To link to a "main article" on a topic, use {{main|The other article}}.
To link to a "main article" on a topic, use <nowiki>{{Main|The other article}</nowiki>}.


=== Advanced Usage (Multiple main articles) ===
=== Advanced Usage (Multiple main articles) ===

Revision as of 12:33, August 16, 2010

Main article: [[{{{1}}}|{{{1}}}]]


Usage

To link to a "main article" on a topic, use {{Main|The other article}}.

Advanced Usage (Multiple main articles)

For multiple main articles, use {{Main|Main Article 1|Main Article 2}}. Up to ten main articles may be listed.

Advanced Usage (Changing a Link's Name)

You may want the main article's name to show up differently; named parameters are good for the job.

{{Main
|1=Main Article 1
|l1=Link Title 1
|2=Main Article 2
|l2=Link Title 2
}}

Note that the named parameters are a lowercase "L" and a number, not the number 1 and then another number.

Advanced Usage (Interwiki Link)

This template is also capable of redirecting to any wiki. Note: To link articles in Halopedia, make sure the "wiki" path is removed and make sure the links you added are accurate. Wiki refers to the domain of the wiki. For instance, Halopedia's domain is halo, Red vs Blue domain is rvb, World of Warcraft's domain is wow.

{{Main
|wiki=
|1=
}}

Example

This template also has an additional feature. Below is an example

  • 1= refers to the actual link.
  • l1= refers to an optional yet customisable title for the link.
{{Main
|wiki=rvb
|1=Michael J. Caboose
|l1=Caboose Blue Team
}}