Difference between revisions of "Template:For"

From Wiki

Jump to: navigation, search
(first draft of the template (not working))
 
(correction)
 
Line 1: Line 1:
[[:Template:For]] provides a [[:wikipedia:Wikipedia:Hatnote|hatnote]] that provides disambiguation between articles. This is useful in cases of multiple articles sharing a similar name. In the Geni project wiki, it is also be used to link between a proposal and its corresponding article. This template is conventionally used at the top of the article or at the beginning of a section.
+
<onlyinclude><div style="padding-left:2em">''For {{{1|other uses}}}, see [[:{{{2|{{PAGENAME}} (disambiguation)}}}|{{{2|{{PAGENAME}} (disambiguation)}}}]].''</div></onlyinclude>
  
This template provides disambiguation in one of two ways: a dedicated page, or a direct link. The dedicated page is of the form <code><nowiki>{{PAGENAME}} (disambiguation)</nowiki></code>, and is useful if the article has a very common name. The direct link should be used if there is only one other related article, as this method is more convenient for readers.
+
{{tempdoc}}
 
+
[[Category:Templates]]
To use this template, insert <code><nowiki>{{for}}</nowiki></code> which will display the default message and link to a dedicated disambiguation page for that article. To link to the related article directly, insert <code><nowiki>{{for|the article on the number four|four}}</nowiki></code>.
+
 
+
== Examples ==
+
=== Dedicated page ===
+
This example demonstrates a dedicated disambiguation page.
+
<pre>{{for}}</pre>
+
''Output:''
+
{{for}}
+
=== Direct link ===
+
This example demonstrates a direct link to a related article.
+
<pre>{{for|an article on the number|four}}</pre>
+
''Output:''
+
{{for|an article on the number|four}}
+

Latest revision as of 09:19, 20 June 2018

For other uses, see For (disambiguation).
Template documentation [edit]
This documentation is transcluded from Template:For/doc. It will not be transcluded on pages that use this template.

Template:For provides a hatnote that provides disambiguation between articles. This is useful in cases of multiple articles sharing a similar name. In the Geni project wiki, it is also be used to link between a proposal and its corresponding article. This template is conventionally used at the top of the article or at the beginning of a section.

This template provides disambiguation in one of two ways: a dedicated page, or a direct link. The dedicated page is of the form {{PAGENAME}} (disambiguation), and is useful if the article has a very common name. The direct link should be used if there is only one other related article, as this method is more convenient for readers.

To use this template, insert {{for}} which will display the default message and link to a dedicated disambiguation page for that article. To link to the related article directly, insert {{for|the article on the number four|four}}.

[edit] Examples

[edit] Dedicated page

This example demonstrates a dedicated disambiguation page.

{{for}}

Output:

For other uses, see For (disambiguation).

[edit] Direct link

This example demonstrates a direct link to a related article.

{{for|an article on the number|four}}

Output:

For an article on the number, see four.
Personal tools