Difference between revisions of "Template:Commons category-inline/doc"

From blackwiki
Jump to navigation Jump to search
imported>Absgomz66
(Manage Template)
imported>Titodutta
(Reverted to revision 905795181 by DocWatson42 (talk): Does not seem to be constructive (Twinkle Twinkle...))
Line 1: Line 1:
{{Documentation subspace}}
+
{{Documentation subpage}}
<!-- PLEASE ADD CATEGORIES AND INTER WIKIS AT THE BOTTOM OF THIS PAGE -->
+
<!-- PLEASE ADD CATEGORIES AND INTERWIKIS AT THE BOTTOM OF THIS PAGE -->
{{template shortcut|Commons cat-inline}}
+
{{template shortcut|Commonscat-inline}}
{{Uses Wiki data|P373}}
+
{{Uses Wikidata|P373}}
  
 
==Purpose==
 
==Purpose==
This template can be used to generate a link to a [[commons:Commons:Categories|Commons category]]. It is intended for use in the "[[WP:LAYOUT|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==
 
==Usage==
<kid><no wiki>* {{Commons category-inline|Usurers Mauritius}}</no wiki></kid>
+
<kbd><nowiki>* {{Commons category-inline|Ursus maritimus}}</nowiki></kbd>
  
 
yields:
 
yields:
* {{Commons category-inline|Usurers Mauritius}}
+
* {{Commons category-inline|Ursus maritimus}}
 
----
 
----
<kid><no wiki>* {{Commons category-inline|Usurers Mauritius|Polar bears}}</no wiki></kid>
+
<kbd><nowiki>* {{Commons category-inline|Ursus maritimus|Polar bears}}</nowiki></kbd>
  
 
yields:
 
yields:
* {{Commons category-inline|Usurers Mauritius|Polar bears}}
+
* {{Commons category-inline|Ursus maritimus|Polar bears}}
 
----
 
----
<kid><no wiki>* {{Commons category-inline|Usurers Mauritius|''Usurers Mauritius''}}</no wiki></kid>
+
<kbd><nowiki>* {{Commons category-inline|Ursus maritimus|''Ursus maritimus''}}</nowiki></kbd>
  
 
yields:
 
yields:
* {{Commons category-inline|Usurers Mauritius|''Usurers Mauritius''}}
+
* {{Commons category-inline|Ursus maritimus|''Ursus maritimus''}}
  
==Template Data==
+
==TemplateData==
{{Template's}}
+
{{TemplateDataHeader}}
<Template Data>
+
<TemplateData>
 
{
 
{
 
         "description": "This template creates a link to a category on Commons.",
 
         "description": "This template creates a link to a category on Commons.",
         "prams": {
+
         "params": {
 
                 "1": {
 
                 "1": {
 
                         "label": "Category name",
 
                         "label": "Category name",
                         "description": "The name of the Commons category this template will link to. If no value is provided the Wiki data property P373 or page name is used by default.",
+
                         "description": "The name of the Commons category this template will link to. If no value is provided the Wikidata property P373 or page name is used by default.",
 
                         "type": "string",
 
                         "type": "string",
 
                         "required": false
 
                         "required": false
Line 43: Line 43:
 
         }
 
         }
 
}
 
}
</Template Data>
+
</TemplateData>
  
 
==Tracking categories==
 
==Tracking categories==
 
=== Normal categories ===
 
=== Normal categories ===
* {{cl|Commons category link from Wiki data}}
+
* {{clc|Commons category link from Wikidata}}
* {{cl|Commons category link is on Wiki data}}
+
* {{clc|Commons category link is on Wikidata}}
 
=== Maintenance categories ===
 
=== Maintenance categories ===
* {{cl|Commons category link is on Wiki data using P373}}
+
* {{clc|Commons category link is on Wikidata using P373}}
* {{cl|Commons category link is defined as the page name}}
+
* {{clc|Commons category link is defined as the pagename}}
* {{cl|Commons category link is locally defined}}
+
* {{clc|Commons category link is locally defined}}
* {{cl|Commons category link is the page name}}
+
* {{clc|Commons category link is the pagename}}
  
 
==See also==
 
==See also==
 
* {{section link|Wikipedia:Manual of Style/Layout#External links}}
 
* {{section link|Wikipedia:Manual of Style/Layout#External links}}
* {{tel|Commons}}
+
* {{tl|Commons}}
* {{tel|Commons-inline}}—shows Commons gallery inline
+
* {{tl|Commons-inline}}—shows Commons gallery inline
* {{tel|Commons category}}
+
* {{tl|Commons category}}
* {{tel|Commons category multi}}—to list up to six categories
+
* {{tl|Commons category multi}}—to list up to six categories
* {{tel|Commons and category}}—shows Commons gallery and category
+
* {{tl|Commons and category}}—shows Commons gallery and category
* {{tel|Commons and category-inline}}—shows Commons gallery and category inline
+
* {{tl|Commons and category-inline}}—shows Commons gallery and category inline
* {{tel|Commons redirect}}—specialized soft redirect template for Commons
+
* {{tl|Commons redirect}}—specialized soft redirect template for Commons
* {{tel|Sister project links}}—to link all Wikinews, Wikisource, etc.
+
* {{tl|Sister project links}}—to link all Wikinews, Wikisource, etc.
* {{tel|Wikibooks-inline}}
+
* {{tl|Wikibooks-inline}}
* {{tel|Wikinews-inline}}
+
* {{tl|Wikinews-inline}}
* {{tel|Wikiquote-inline}}
+
* {{tl|Wikiquote-inline}}
* {{tel|Wikisource-inline}}
+
* {{tl|Wikisource-inline}}
* {{tel|Wiki species-inline}}
+
* {{tl|Wikispecies-inline}}
* {{tel|Diversity-inline}}
+
* {{tl|Wikiversity-inline}}
* {{tel|Wiktionary-inline}}
+
* {{tl|Wiktionary-inline}}
  
<include only>{{#fife:{{SUBPOENA}}|sandbox||
+
<includeonly>{{#ifeq:{{SUBPAGENAME}}|sandbox||
<!-- CATEGORIES AND INTER WIKIS HERE, THANKS -->
+
<!-- CATEGORIES AND INTERWIKIS HERE, THANKS -->
 
[[Category:Exclude in print]]
 
[[Category:Exclude in print]]
[[Category:Inter wiki category linking templates]]
+
[[Category:Interwiki category linking templates]]
[[Category:Inter wiki link templates]]
+
[[Category:Interwiki link templates]]
 
[[Category:Wikimedia Commons templates]]
 
[[Category:Wikimedia Commons templates]]
  
[[ed:Voltage:Commons cat]]<!-- in German Wikipedia common scat-template itself is formatted inline -->
+
[[de:Vorlage:Commonscat]]<!-- in German Wikipedia commonscat-template itself is formated inline -->
}}</include only>
+
}}</includeonly>

Revision as of 21:32, 30 August 2019

Template:Uses Wikidata

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:


* {{Commons category-inline|Ursus maritimus|Polar bears}}

yields:


* {{Commons category-inline|Ursus maritimus|''Ursus maritimus''}}

yields:

TemplateData

This is the TemplateData documentation for this template used by VisualEditor and other tools; see the monthly parameter usage report for this template.

TemplateData for Commons category-inline

This template creates a link to a category on Commons.

Template parameters

ParameterDescriptionTypeStatus
Category name1

The name of the Commons category this template will link to. If no value is provided the Wikidata property P373 or page name is used by default.

Stringoptional
Displayed text2

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.

Stringoptional

Tracking categories

Normal categories

Maintenance categories

See also