Difference between revisions of "Template:Commons category-inline/doc"
imported>Izno (add wikibooks inline) |
imported>Jonesey95 (add high use) |
||
| (46 intermediate revisions by 36 users not shown) | |||
| Line 1: | Line 1: | ||
{{Documentation subpage}} | {{Documentation subpage}} | ||
| + | {{high use}} | ||
<!-- PLEASE ADD CATEGORIES AND INTERWIKIS AT THE BOTTOM OF THIS PAGE --> | <!-- PLEASE ADD CATEGORIES AND INTERWIKIS AT THE BOTTOM OF THIS PAGE --> | ||
| − | + | {{template shortcut|Commonscat-inline}} | |
| − | + | ==Purpose== | |
| − | This template can be used to generate a link to a [[commons:Commons:Categories|Commons category]]. It intended for use in the "External links" section of an article. | + | This template can be used to generate a link to a [[commons:Commons:Categories|Commons category]]. It is intended for use in the "[[WP:LAYOUTEL|External links]]" section of an article. |
| − | + | ==Usage== | |
| − | < | + | <kbd><nowiki>* {{Commons category-inline|Ursus maritimus}}</nowiki></kbd> |
| − | yields: {{Commons category-inline|Ursus maritimus}} | + | yields: |
| + | * {{Commons category-inline|Ursus maritimus}} | ||
---- | ---- | ||
| − | < | + | <kbd><nowiki>* {{Commons category-inline|Ursus maritimus|Polar bears}}</nowiki></kbd> |
| − | yields: {{Commons category-inline|Ursus maritimus|Polar bears}} | + | yields: |
| + | * {{Commons category-inline|Ursus maritimus|Polar bears}} | ||
---- | ---- | ||
| − | < | + | <kbd><nowiki>* {{Commons category-inline|Ursus maritimus|''Ursus maritimus''}}</nowiki></kbd> |
| − | yields: {{Commons category-inline|Ursus maritimus| | + | yields: |
| + | * {{Commons category-inline|Ursus maritimus|''Ursus maritimus''}} | ||
| − | == | + | ==TemplateData== |
| − | + | {{TemplateDataHeader}} | |
| − | + | <TemplateData> | |
| − | + | { | |
| + | "description": "This template creates a link to a category on Commons.", | ||
| + | "params": { | ||
| + | "1": { | ||
| + | "label": "Category name", | ||
| + | "description": "The name of the Commons category this template will link to. If no value is provided the Wikidata sitelinks are used by default.", | ||
| + | "type": "string", | ||
| + | "required": false | ||
| + | }, | ||
| + | "2": { | ||
| + | "label": "Displayed text", | ||
| + | "description": "The text that the link will display to the user. If no value is provided it will default to category name or page name, in that order.", | ||
| + | "type": "string", | ||
| + | "required": false | ||
| + | }, | ||
| + | "nowrap": { | ||
| + | "label": "nowrap", | ||
| + | "description": "Stops the text of the commons category from wrapping", | ||
| + | "type": "string", | ||
| + | "required": false | ||
| + | }, | ||
| + | "lcfirst": { | ||
| + | "label": "lcfirst", | ||
| + | "description": "Displays the first letter as lower-case", | ||
| + | "type": "string", | ||
| + | "required": false | ||
| + | } | ||
| + | } | ||
| + | } | ||
| + | </TemplateData> | ||
| − | * {{tl|Commons-inline}} | + | ==Tracking categories== |
| − | * {{tl|Commons category-inline}} | + | === Normal categories === |
| + | * {{clc|Commons category link from Wikidata}} | ||
| + | * {{clc|Commons category link is on Wikidata}} | ||
| + | === Maintenance categories === | ||
| + | * {{clc|Commons category link is defined as the pagename}} | ||
| + | * {{clc|Commons category link is locally defined}} | ||
| + | * {{clc|Commons category link is the pagename}} | ||
| + | |||
| + | ==See also== | ||
| + | * {{section link|Wikipedia:Manual of Style/Layout#External links}} | ||
| + | * {{tl|Commons}} | ||
| + | * {{tl|Commons-inline}}—shows Commons gallery inline | ||
| + | * {{tl|Commons category}} | ||
| + | * {{tl|Commons category multi}}—to list up to six categories | ||
| + | * {{tl|Commons and category}}—shows Commons gallery and category | ||
| + | * {{tl|Commons and category-inline}}—shows Commons gallery and category inline | ||
| + | * {{tl|Wikimedia Commons redirect}}—specialized soft redirect template for Commons | ||
| + | * {{tl|Sister project links}}—to link all Wikinews, Wikisource, etc. | ||
| + | * {{tl|Wikibooks-inline}} | ||
* {{tl|Wikinews-inline}} | * {{tl|Wikinews-inline}} | ||
* {{tl|Wikiquote-inline}} | * {{tl|Wikiquote-inline}} | ||
* {{tl|Wikisource-inline}} | * {{tl|Wikisource-inline}} | ||
* {{tl|Wikispecies-inline}} | * {{tl|Wikispecies-inline}} | ||
| + | * {{tl|Wikiversity-inline}} | ||
* {{tl|Wiktionary-inline}} | * {{tl|Wiktionary-inline}} | ||
| − | + | ||
| − | + | <includeonly>{{Sandbox other|| | |
| − | |||
<!-- CATEGORIES AND INTERWIKIS HERE, THANKS --> | <!-- CATEGORIES AND INTERWIKIS HERE, THANKS --> | ||
[[Category:Exclude in print]] | [[Category:Exclude in print]] | ||
| − | [[Category:Interwiki | + | [[Category:Interwiki category linking templates]] |
| − | [[Category:Interwiki | + | [[Category:Interwiki link templates]] |
| − | [[Category:Wikimedia Commons templates | + | [[Category:Wikimedia Commons templates]] |
| − | [[ | + | [[de:Vorlage:Commonscat]]<!-- in German Wikipedia commonscat-template itself is formated inline --> |
| − | + | }}</includeonly> | |
| − | |||
| − | |||
| − | </includeonly> | ||
Latest revision as of 14:12, 16 November 2020
| This is a documentation subpage for Template:Commons category-inline. It contains usage information, categories and other content that is not part of the original template page. |
| This template is used on approximately 110,000 pages. To avoid major disruption and server load, any changes should be tested in the template's /sandbox or /testcases subpages, or in your own user subpage. The tested changes can be added to this page in a single edit. Consider discussing changes on the talk page before implementing them. Transclusion count updated automatically (see documentation). |
Contents
Purpose
This template can be used to generate a link to a Commons category. It is intended for use in the "External links" section of an article.
Usage
* {{Commons category-inline|Ursus maritimus}}
yields:
Media related to Ursus maritimus at Wikimedia Commons
* {{Commons category-inline|Ursus maritimus|Polar bears}}
yields:
Media related to Polar bears at Wikimedia Commons
* {{Commons category-inline|Ursus maritimus|''Ursus maritimus''}}
yields:
Media related to Ursus maritimus at Wikimedia Commons
TemplateData
TemplateData for Commons category-inline
This template creates a link to a category on Commons.
| Parameter | Description | Type | Status | |
|---|---|---|---|---|
| Category name | 1 | The name of the Commons category this template will link to. If no value is provided the Wikidata sitelinks are used by default. | String | optional |
| Displayed text | 2 | The text that the link will display to the user. If no value is provided it will default to category name or page name, in that order. | String | optional |
| nowrap | nowrap | Stops the text of the commons category from wrapping | String | optional |
| lcfirst | lcfirst | Displays the first letter as lower-case | String | optional |
Tracking categories
Normal categories
Maintenance categories
- Category:Commons category link is defined as the pagename (1)
- Category:Commons category link is locally defined (1)
- Category:Commons category link is the pagename (0)
See also
- Script error: No such module "Section link".
- {{Commons}}
- {{Commons-inline}}—shows Commons gallery inline
- {{Commons category}}
- {{Commons category multi}}—to list up to six categories
- {{Commons and category}}—shows Commons gallery and category
- {{Commons and category-inline}}—shows Commons gallery and category inline
- {{Wikimedia Commons redirect}}—specialized soft redirect template for Commons
- {{Sister project links}}—to link all Wikinews, Wikisource, etc.
- {{Wikibooks-inline}}
- {{Wikinews-inline}}
- {{Wikiquote-inline}}
- {{Wikisource-inline}}
- {{Wikispecies-inline}}
- {{Wikiversity-inline}}
- {{Wiktionary-inline}}