Template:Category if exists/doc
This is a documentation subpage for Template:Category if exists. It may contain usage information, categories and other content that is not part of the original template page. |
This template uses Lua: |
This template outputs a category if the category exists. Otherwise, it returns nothing. It is intended for use in templates.
This template follows category redirects (using {{resolve category redirect}}).
TemplateData
changeOutputs a link to a category if it exists; otherwise returns nothing.
Parameter | Description | Type | Status | |
---|---|---|---|---|
Category name | 1 | Category for potential inclusion if it exists. "Category:" prefix is optional.
| Page name | required |
Sort key | 2 | [[WP:SORTKEY]] of the category.
| Line | optional |