Template:Category/doc
From MozillaWiki
Contents
Usage
This template produces a link to a category. It's meant to be an easier way to link to categories.
The current syntax for creating a link to a category, [[:Category:Category Name]], is confusingly similar to the syntax for adding a page to a category, [[Category:Category Name]] (only a single colon character differs).
Parameters
The syntax for {{category}} is {{category|category name|link text}}
, where
- category name is the name of the category to which you want to link.
- link text is an alternative text for the link, that is displayed instead of the standard output "Category:Category name".
NB! The template automatically includes the preceding namespace, "Category:". Hence, if you, as an example, want to link to a category called Mozilla, you just enter "Mozilla".
Examples
-
{{category|L10n}}
gives Category:L10n -
{{category|Gurkburk}}
gives Category:Gurkburk
-
{{category|L10n|localization}}
gives localization -
{{category|Gurkburk|This category doesn't exist! (Yet)}}
gives This category doesn't exist! (Yet)
If the resulting link is displayed in red, it means that the category you wished to link to doesn't exist yet. Click the link to go to the page for creating that category.
See also
- {{c}} – same function as this template, but without the option to add a custom link text.