Template:Main/doc: Difference between revisions

From IxWiki
Jump to navigation Jump to search
deprecate Template:Wikipedia template
m 1 revision imported
 
(One intermediate revision by the same user not shown)
Line 1: Line 1:
{{Documentation|fromWikipedia=true}}
This template is for linking to the main article on a subject (duh).  If an article contains a section about a subject in brief, and RationalWiki happens to have an entire article already devoted to that subject, then this template would be used to direct others to the proper article on the subject.  Its utility differs from casually linking to another article in within the text and from a "See also" section in that it highlights a specific and highly relevant article.
This template has six parameters.


This template is used at the start of a section to link to the main article on that subject.
The first (and required) parameter is simply the name of the article you're linking to. For example, <code><nowiki>{{main|9/11 conspiracy theories}}</nowiki></code> produces  {{main|9/11 conspiracy theories}}


==TemplateData==
There is a second, optional parameter which allows you to change the text of the link. For example, <code><nowiki>{{main|9/11 conspiracy theories|What crazy people believe}}</nowiki></code> produces {{main|9/11 conspiracy theories|What crazy people believe}}
<templatedata>
{
"description": "This template is used after the heading of a section, to link to a sub-article (or sub-articles) that is entirely about the topic of the section. The template will display, in italics, \"Main article: Article 1, Article 2 and Article 3\"",
"params": {
"1": {
"label": "Page 1",
"description": "The name of the first page that you want to link to. If this is not specified, the current page name (with no namespace prefix) is used instead. ",
"type": "wiki-page-name",
"required": false,
"suggested": true
},
"2": {
"label": "Page 2",
"description": "The name of the second page that you want to link to.",
"type": "wiki-page-name",
"required": false
},
"3": {
"label": "Page 3",
"description": "The name of the third page that you want to link to. More pages can be added using the parameters \"4\", \"5\", etc.",
"type": "wiki-page-name",
"required": false
},
"l1": {
"type": "string",
"label": "Label 1",
"description": "What the first linked page is to be displayed as.",
"aliases": [
"label 1"
]
},
"l2": {
"label": "Label 2",
"description": "What the second linked page is to be displayed as.",
"type": "string",
"aliases": [
"label 2"
]
},
"l3": {
"label": "Label 3",
"description": "What the third linked page is to be displayed as. Other labels can be added by using increasing numbers (starting with \"l4\" for page 4) as parameter names.",
"type": "string",
"aliases": [
"label 3"
]
},
"selfref": {
"type": "boolean",
"label": "Self reference",
"description": "Set to \"yes\" if the template is a self-reference to Wikipedia that would not make sense on mirrors or forks of the Wikipedia site."
}
},
"paramOrder": [
"1",
"2",
"3",
"l1",
"l2",
"l3",
"selfref"
],
"format": "{{_|_ = _}}\n"
}
</templatedata>


<includeonly>[[Category:General wiki templates|{{PAGENAME}}]]</includeonly>
The third parameter adds a second article, the fourth changes the text of that link; the fifth parameter adds a third article, the sixth changes the text of that link. Or:
 
<pre>
{{main|1=one|3=two|5=three}}
</pre>
 
Example:
 
{{main|Kirk Cameron|3=Ray Comfort}}
 
{{Template}}
 
<includeonly>
[[Category:In-text templates]]
 
</includeonly>

Latest revision as of 01:43, 2 August 2024

This template is for linking to the main article on a subject (duh). If an article contains a section about a subject in brief, and RationalWiki happens to have an entire article already devoted to that subject, then this template would be used to direct others to the proper article on the subject. Its utility differs from casually linking to another article in within the text and from a "See also" section in that it highlights a specific and highly relevant article.

This template has six parameters.

The first (and required) parameter is simply the name of the article you're linking to. For example, {{main|9/11 conspiracy theories}} produces

There is a second, optional parameter which allows you to change the text of the link. For example, {{main|9/11 conspiracy theories|What crazy people believe}} produces

The third parameter adds a second article, the fourth changes the text of that link; the fifth parameter adds a third article, the sixth changes the text of that link. Or:

{{main|1=one|3=two|5=three}}

Example:

{{[[Template:{{{1}}}|{{{1}}}]]}}