Template:Category redirect: Difference between revisions

Content deleted Content added
m
reformatted for clarity. (kept #default as it was even though it makes no sense)
Line 1:
{{#switch:{{NAMESPACE}}
|Category = <!-- correct namespace, work as intended
|Template|Commons = {{Autotranslate|1={{ucfirst:{{{1|}}}}}|base=Category redirect}}
|Category = -->{{Autotranslate|1={{ucfirst:{{{1|}}}}}|base=Category redirect}}<!--
-->{{Nuke|{{FULLPAGENAME}} moved to [[:Category:{{{1}}}]]}}<!--
-->{{{category|<!--
-->{{#ifexpr:{{PAGESINCAT:{{PAGENAME}}|R}}>0
| [[Category:Non-empty category redirects]][[Category:{{{1}}}|~{{PAGENAME}}]]
}}{{#ifeq:{{NAMESPACE}}|Category|<!--
-->{{#ifeq:{{PAGENAME}}|{{{1}}}
| [[Category:Broken category redirects|*]]
| {{#ifexist:Category:{{{1}}}
| [[Category:Category redirects|{{PAGENAME}}]]|[[Category:Broken
category redirects|!]]}}}}| [[Category:Broken category redirects|-!]]}}}}}
}}
| = {{error|Category redirects should be used in the category namespace only. You may want to use <nowiki>#REDIRECT[[:Category:</nowiki>{{{1|}}}<nowiki>]]</nowiki> instead}}.[[Category:Broken category redirects]]
}}
|#default = {{Category:{{{1|}}}}} [[Category:Broken category redirects]]
}}}
|Commons|Template = <!-- for documentation, don't add categories or nuke icon
|Template|Commons = -->{{Autotranslate|1={{ucfirst:{{{1|}}}}}|base=Category redirect}}
|Gallery = <!-- display error
| = -->{{error|Category redirects should be used in the category namespace only. You may want to use <nowiki>#REDIRECT[[:Category:</nowiki>{{{1|}}}<nowiki>]]</nowiki> instead}}.{{{category|[[Category:Broken category redirects|-]] }}
|#default = <!-- go crazy and transclude a category instead
-->{{Category:{{{1}}}}}
}}<noinclude>
{{documentation}}