Difference between revisions of "Template:Category handler/testcases"
imported>MSGJ m (moved Template:Cat handler/testcases to Template:Category handler/testcases: expand name) |
imported>Plastikspork m (category handler) |
||
| Line 1: | Line 1: | ||
{{template test cases notice}} | {{template test cases notice}} | ||
| − | === Testing {{tl| | + | === Testing {{tl|category handler/numbered}} === |
<pre> | <pre> | ||
| − | x{{ | + | x{{category handler/numbered}}x |
| − | x{{ | + | x{{category handler/numbered |
| 1 = a | | 1 = a | ||
| 2 = b | | 2 = b | ||
| Line 13: | Line 13: | ||
}}x | }}x | ||
| − | x{{ | + | x{{category handler/numbered |
| 1 = a | | 1 = a | ||
| 2 = b | | 2 = b | ||
| Line 20: | Line 20: | ||
}}x | }}x | ||
| − | x{{ | + | x{{category handler/numbered |
| 1 = a | | 1 = a | ||
| 2 = b | | 2 = b | ||
| Line 27: | Line 27: | ||
}}x | }}x | ||
</pre> | </pre> | ||
| − | x{{ | + | x{{category handler/numbered}}x |
| − | x{{ | + | x{{category handler/numbered |
| 1 = a | | 1 = a | ||
| 2 = b | | 2 = b | ||
| Line 36: | Line 36: | ||
}}x | }}x | ||
| − | x{{ | + | x{{category handler/numbered |
| 1 = a | | 1 = a | ||
| 2 = b | | 2 = b | ||
| Line 43: | Line 43: | ||
}}x | }}x | ||
| − | x{{ | + | x{{category handler/numbered |
| 1 = a | | 1 = a | ||
| 2 = b | | 2 = b | ||
| Line 51: | Line 51: | ||
| − | === Testing {{tl| | + | === Testing {{tl|category handler/blacklist}} === |
<pre> | <pre> | ||
| − | x{{ | + | x{{category handler/blacklist}}x |
| − | x{{ | + | x{{category handler/blacklist |
| page = User talk:Example | | page = User talk:Example | ||
}}x | }}x | ||
| − | x{{ | + | x{{category handler/blacklist |
| page = User talk:Example/Archive 5 | | page = User talk:Example/Archive 5 | ||
}}x | }}x | ||
| − | x{{ | + | x{{category handler/blacklist |
| page = Wikipedia:Template messages/Wikipedia namespace | | page = Wikipedia:Template messages/Wikipedia namespace | ||
}}x | }}x | ||
</pre> | </pre> | ||
| − | x{{ | + | x{{category handler/blacklist}}x |
| − | x{{ | + | x{{category handler/blacklist |
| page = User talk:Example | | page = User talk:Example | ||
}}x | }}x | ||
| − | x{{ | + | x{{category handler/blacklist |
| page = User talk:Example/Archive 5 | | page = User talk:Example/Archive 5 | ||
}}x | }}x | ||
| − | x{{ | + | x{{category handler/blacklist |
| page = Wikipedia:Template messages/Wikipedia namespace | | page = Wikipedia:Template messages/Wikipedia namespace | ||
}}x | }}x | ||
| − | === Testing {{tl| | + | === Testing {{tl|category handler}} === |
<pre> | <pre> | ||
| − | x{{ | + | x{{category handler}}x |
| − | x{{ | + | x{{category handler |
| Somecat | | Somecat | ||
}}x | }}x | ||
| − | x{{ | + | x{{category handler |
| template = Somecat | | template = Somecat | ||
}}x | }}x | ||
| − | x{{ | + | x{{category handler |
| Somecat | | Somecat | ||
| page = Somearticle | | page = Somearticle | ||
}}x | }}x | ||
</pre> | </pre> | ||
| − | x{{ | + | x{{category handler}}x |
| − | x{{ | + | x{{category handler |
| Somecat | | Somecat | ||
}}x | }}x | ||
| − | x{{ | + | x{{category handler |
| template = Somecat | | template = Somecat | ||
}}x | }}x | ||
| − | x{{ | + | x{{category handler |
| Somecat | | Somecat | ||
| page = Somearticle | | page = Somearticle | ||
| Line 118: | Line 118: | ||
<pre> | <pre> | ||
| − | x{{ | + | x{{category handler |
| Somecat | | Somecat | ||
| page = File:Example/test | | page = File:Example/test | ||
}}x | }}x | ||
| − | x{{ | + | x{{category handler |
| Somecat | | Somecat | ||
| page = File:Example/test | | page = File:Example/test | ||
| Line 129: | Line 129: | ||
}}x | }}x | ||
| − | x{{ | + | x{{category handler |
| Somecat | | Somecat | ||
| page = File:Example/test | | page = File:Example/test | ||
| Line 135: | Line 135: | ||
}}x | }}x | ||
</pre> | </pre> | ||
| − | x{{ | + | x{{category handler |
| Somecat | | Somecat | ||
| page = File:Example/test | | page = File:Example/test | ||
}}x | }}x | ||
| − | x{{ | + | x{{category handler |
| Somecat | | Somecat | ||
| page = File:Example/test | | page = File:Example/test | ||
| Line 146: | Line 146: | ||
}}x | }}x | ||
| − | x{{ | + | x{{category handler |
| Somecat | | Somecat | ||
| page = File:Example/test | | page = File:Example/test | ||
| Line 155: | Line 155: | ||
<pre> | <pre> | ||
| − | x{{ | + | x{{category handler |
| main = Category:Somecat1 Category:Somecat2 | | main = Category:Somecat1 Category:Somecat2 | ||
| 1 = Category:Somecat3 <!--For help, user and template space--> | | 1 = Category:Somecat3 <!--For help, user and template space--> | ||
| Line 166: | Line 166: | ||
}}x | }}x | ||
| − | x{{ | + | x{{category handler |
| main = Category:Somecat1 Category:Somecat2 | | main = Category:Somecat1 Category:Somecat2 | ||
| 3 = Category:Somecat3 <!--For help, user and template space--> | | 3 = Category:Somecat3 <!--For help, user and template space--> | ||
| Line 177: | Line 177: | ||
}}x | }}x | ||
| − | x{{ | + | x{{category handler |
| main = Category:Somecat1 Category:Somecat2 | | main = Category:Somecat1 Category:Somecat2 | ||
| 3 = Category:Somecat3 <!--For help, user and template space--> | | 3 = Category:Somecat3 <!--For help, user and template space--> | ||
| Line 189: | Line 189: | ||
}}x | }}x | ||
</pre> | </pre> | ||
| − | x{{ | + | x{{category handler |
| main = Category:Somecat1 Category:Somecat2 | | main = Category:Somecat1 Category:Somecat2 | ||
| 1 = Category:Somecat3 <!--For help, user and template space--> | | 1 = Category:Somecat3 <!--For help, user and template space--> | ||
| Line 200: | Line 200: | ||
}}x | }}x | ||
| − | x{{ | + | x{{category handler |
| main = Category:Somecat1 Category:Somecat2 | | main = Category:Somecat1 Category:Somecat2 | ||
| 3 = Category:Somecat3 <!--For help, user and template space--> | | 3 = Category:Somecat3 <!--For help, user and template space--> | ||
| Line 211: | Line 211: | ||
}}x | }}x | ||
| − | x{{ | + | x{{category handler |
| main = Category:Somecat1 Category:Somecat2 | | main = Category:Somecat1 Category:Somecat2 | ||
| 3 = Category:Somecat3 <!--For help, user and template space--> | | 3 = Category:Somecat3 <!--For help, user and template space--> | ||
| Line 226: | Line 226: | ||
<pre> | <pre> | ||
| − | x{{ | + | x{{category handler |
| other = Somecat | | other = Somecat | ||
}}x | }}x | ||
| − | x{{ | + | x{{category handler |
| other = Somecat | | other = Somecat | ||
| page = User talk:Example/Archive 5 | | page = User talk:Example/Archive 5 | ||
}}x | }}x | ||
| − | x{{ | + | x{{category handler |
| other = Somecat | | other = Somecat | ||
| page = User talk:Example/Archive 5 | | page = User talk:Example/Archive 5 | ||
| Line 241: | Line 241: | ||
}}x | }}x | ||
</pre> | </pre> | ||
| − | x{{ | + | x{{category handler |
| other = Somecat | | other = Somecat | ||
}}x | }}x | ||
| − | x{{ | + | x{{category handler |
| other = Somecat | | other = Somecat | ||
| page = User talk:Example/Archive 5 | | page = User talk:Example/Archive 5 | ||
}}x | }}x | ||
| − | x{{ | + | x{{category handler |
| other = Somecat | | other = Somecat | ||
| page = User talk:Example/Archive 5 | | page = User talk:Example/Archive 5 | ||
| Line 259: | Line 259: | ||
<pre> | <pre> | ||
| − | x{{ | + | x{{category handler |
| other = Somecat | | other = Somecat | ||
| categories = no | | categories = no | ||
}}x | }}x | ||
| − | x{{ | + | x{{category handler |
| other = Somecat | | other = Somecat | ||
| page = User talk:Example/Archive 5 | | page = User talk:Example/Archive 5 | ||
| Line 270: | Line 270: | ||
}}x | }}x | ||
</pre> | </pre> | ||
| − | x{{ | + | x{{category handler |
| other = Somecat | | other = Somecat | ||
| categories = no | | categories = no | ||
}}x | }}x | ||
| − | x{{ | + | x{{category handler |
| other = Somecat | | other = Somecat | ||
| page = User talk:Example/Archive 5 | | page = User talk:Example/Archive 5 | ||
| Line 284: | Line 284: | ||
<pre> | <pre> | ||
| − | x{{ | + | x{{category handler |
| other = Somecat | | other = Somecat | ||
| category2 = no | | category2 = no | ||
}}x | }}x | ||
| − | x{{ | + | x{{category handler |
| other = Somecat | | other = Somecat | ||
| category2 = | | category2 = | ||
}}x | }}x | ||
| − | x{{ | + | x{{category handler |
| other = Somecat | | other = Somecat | ||
| category2 = ¬ | | category2 = ¬ | ||
}}x | }}x | ||
| − | x{{ | + | x{{category handler |
| other = Somecat | | other = Somecat | ||
| category2 = {{{category|¬}}} | | category2 = {{{category|¬}}} | ||
}}x | }}x | ||
| − | x{{ | + | x{{category handler |
| other = Somecat | | other = Somecat | ||
| page = User talk:Example/Archive 5 | | page = User talk:Example/Archive 5 | ||
| Line 311: | Line 311: | ||
</pre> | </pre> | ||
| − | x{{ | + | x{{category handler |
| other = Somecat | | other = Somecat | ||
| category2 = no | | category2 = no | ||
}}x | }}x | ||
| − | x{{ | + | x{{category handler |
| other = Somecat | | other = Somecat | ||
| category2 = | | category2 = | ||
}}x | }}x | ||
| − | x{{ | + | x{{category handler |
| other = Somecat | | other = Somecat | ||
| category2 = ¬ | | category2 = ¬ | ||
}}x | }}x | ||
| − | x{{ | + | x{{category handler |
| other = Somecat | | other = Somecat | ||
| category2 = {{{category|¬}}} | | category2 = {{{category|¬}}} | ||
}}x | }}x | ||
| − | x{{ | + | x{{category handler |
| other = Somecat | | other = Somecat | ||
| page = User talk:Example/Archive 5 | | page = User talk:Example/Archive 5 | ||
| Line 337: | Line 337: | ||
}}x | }}x | ||
| − | === Testing {{tl| | + | === Testing {{tl|category handler/sandbox}} === |
<pre> | <pre> | ||
| − | x{{ | + | x{{category handler/sandbox}}x |
| − | x{{ | + | x{{category handler/sandbox |
| Somecat | | Somecat | ||
}}x | }}x | ||
| − | x{{ | + | x{{category handler/sandbox |
| template = Somecat | | template = Somecat | ||
}}x | }}x | ||
| − | x{{ | + | x{{category handler/sandbox |
| Somecat | | Somecat | ||
| page = Somearticle | | page = Somearticle | ||
}}x | }}x | ||
</pre> | </pre> | ||
| − | x{{ | + | x{{category handler/sandbox}}x |
| − | x{{ | + | x{{category handler/sandbox |
| Somecat | | Somecat | ||
}}x | }}x | ||
| − | x{{ | + | x{{category handler/sandbox |
| template = Somecat | | template = Somecat | ||
}}x | }}x | ||
| − | x{{ | + | x{{category handler/sandbox |
| Somecat | | Somecat | ||
| page = Somearticle | | page = Somearticle | ||
| Line 373: | Line 373: | ||
<pre> | <pre> | ||
| − | x{{ | + | x{{category handler/sandbox |
| Somecat | | Somecat | ||
| page = File:Example/test | | page = File:Example/test | ||
}}x | }}x | ||
| − | x{{ | + | x{{category handler/sandbox |
| Somecat | | Somecat | ||
| page = File:Example/test | | page = File:Example/test | ||
| Line 384: | Line 384: | ||
}}x | }}x | ||
| − | x{{ | + | x{{category handler/sandbox |
| Somecat | | Somecat | ||
| page = File:Example/test | | page = File:Example/test | ||
| Line 390: | Line 390: | ||
}}x | }}x | ||
</pre> | </pre> | ||
| − | x{{ | + | x{{category handler/sandbox |
| Somecat | | Somecat | ||
| page = File:Example/test | | page = File:Example/test | ||
}}x | }}x | ||
| − | x{{ | + | x{{category handler/sandbox |
| Somecat | | Somecat | ||
| page = File:Example/test | | page = File:Example/test | ||
| Line 401: | Line 401: | ||
}}x | }}x | ||
| − | x{{ | + | x{{category handler/sandbox |
| Somecat | | Somecat | ||
| page = File:Example/test | | page = File:Example/test | ||
| Line 410: | Line 410: | ||
<pre> | <pre> | ||
| − | x{{ | + | x{{category handler/sandbox |
| main = Category:Somecat1 Category:Somecat2 | | main = Category:Somecat1 Category:Somecat2 | ||
| 1 = Category:Somecat3 <!--For help, user and template space--> | | 1 = Category:Somecat3 <!--For help, user and template space--> | ||
| Line 421: | Line 421: | ||
}}x | }}x | ||
| − | x{{ | + | x{{category handler/sandbox |
| main = Category:Somecat1 Category:Somecat2 | | main = Category:Somecat1 Category:Somecat2 | ||
| 3 = Category:Somecat3 <!--For help, user and template space--> | | 3 = Category:Somecat3 <!--For help, user and template space--> | ||
| Line 432: | Line 432: | ||
}}x | }}x | ||
| − | x{{ | + | x{{category handler/sandbox |
| main = Category:Somecat1 Category:Somecat2 | | main = Category:Somecat1 Category:Somecat2 | ||
| 3 = Category:Somecat3 <!--For help, user and template space--> | | 3 = Category:Somecat3 <!--For help, user and template space--> | ||
| Line 444: | Line 444: | ||
}}x | }}x | ||
</pre> | </pre> | ||
| − | x{{ | + | x{{category handler/sandbox |
| main = Category:Somecat1 Category:Somecat2 | | main = Category:Somecat1 Category:Somecat2 | ||
| 1 = Category:Somecat3 <!--For help, user and template space--> | | 1 = Category:Somecat3 <!--For help, user and template space--> | ||
| Line 455: | Line 455: | ||
}}x | }}x | ||
| − | x{{ | + | x{{category handler/sandbox |
| main = Category:Somecat1 Category:Somecat2 | | main = Category:Somecat1 Category:Somecat2 | ||
| 3 = Category:Somecat3 <!--For help, user and template space--> | | 3 = Category:Somecat3 <!--For help, user and template space--> | ||
| Line 466: | Line 466: | ||
}}x | }}x | ||
| − | x{{ | + | x{{category handler/sandbox |
| main = Category:Somecat1 Category:Somecat2 | | main = Category:Somecat1 Category:Somecat2 | ||
| 3 = Category:Somecat3 <!--For help, user and template space--> | | 3 = Category:Somecat3 <!--For help, user and template space--> | ||
| Line 481: | Line 481: | ||
<pre> | <pre> | ||
| − | x{{ | + | x{{category handler/sandbox |
| other = Somecat | | other = Somecat | ||
}}x | }}x | ||
| − | x{{ | + | x{{category handler/sandbox |
| other = Somecat | | other = Somecat | ||
| page = User talk:Example/Archive 5 | | page = User talk:Example/Archive 5 | ||
}}x | }}x | ||
| − | x{{ | + | x{{category handler/sandbox |
| other = Somecat | | other = Somecat | ||
| page = User talk:Example/Archive 5 | | page = User talk:Example/Archive 5 | ||
| Line 496: | Line 496: | ||
}}x | }}x | ||
</pre> | </pre> | ||
| − | x{{ | + | x{{category handler/sandbox |
| other = Somecat | | other = Somecat | ||
}}x | }}x | ||
| − | x{{ | + | x{{category handler/sandbox |
| other = Somecat | | other = Somecat | ||
| page = User talk:Example/Archive 5 | | page = User talk:Example/Archive 5 | ||
}}x | }}x | ||
| − | x{{ | + | x{{category handler/sandbox |
| other = Somecat | | other = Somecat | ||
| page = User talk:Example/Archive 5 | | page = User talk:Example/Archive 5 | ||
| Line 514: | Line 514: | ||
<pre> | <pre> | ||
| − | x{{ | + | x{{category handler/sandbox |
| other = Somecat | | other = Somecat | ||
| categories = no | | categories = no | ||
}}x | }}x | ||
| − | x{{ | + | x{{category handler/sandbox |
| other = Somecat | | other = Somecat | ||
| page = User talk:Example/Archive 5 | | page = User talk:Example/Archive 5 | ||
| Line 525: | Line 525: | ||
}}x | }}x | ||
</pre> | </pre> | ||
| − | x{{ | + | x{{category handler/sandbox |
| other = Somecat | | other = Somecat | ||
| categories = no | | categories = no | ||
}}x | }}x | ||
| − | x{{ | + | x{{category handler/sandbox |
| other = Somecat | | other = Somecat | ||
| page = User talk:Example/Archive 5 | | page = User talk:Example/Archive 5 | ||
| Line 539: | Line 539: | ||
<pre> | <pre> | ||
| − | x{{ | + | x{{category handler/sandbox |
| other = Somecat | | other = Somecat | ||
| category2 = no | | category2 = no | ||
}}x | }}x | ||
| − | x{{ | + | x{{category handler/sandbox |
| other = Somecat | | other = Somecat | ||
| category2 = | | category2 = | ||
}}x | }}x | ||
| − | x{{ | + | x{{category handler/sandbox |
| other = Somecat | | other = Somecat | ||
| category2 = ¬ | | category2 = ¬ | ||
}}x | }}x | ||
| − | x{{ | + | x{{category handler/sandbox |
| other = Somecat | | other = Somecat | ||
| category2 = {{{category|¬}}} | | category2 = {{{category|¬}}} | ||
}}x | }}x | ||
| − | x{{ | + | x{{category handler/sandbox |
| other = Somecat | | other = Somecat | ||
| page = User talk:Example/Archive 5 | | page = User talk:Example/Archive 5 | ||
| Line 566: | Line 566: | ||
</pre> | </pre> | ||
| − | x{{ | + | x{{category handler/sandbox |
| other = Somecat | | other = Somecat | ||
| category2 = no | | category2 = no | ||
}}x | }}x | ||
| − | x{{ | + | x{{category handler/sandbox |
| other = Somecat | | other = Somecat | ||
| category2 = | | category2 = | ||
}}x | }}x | ||
| − | x{{ | + | x{{category handler/sandbox |
| other = Somecat | | other = Somecat | ||
| category2 = ¬ | | category2 = ¬ | ||
}}x | }}x | ||
| − | x{{ | + | x{{category handler/sandbox |
| other = Somecat | | other = Somecat | ||
| category2 = {{{category|¬}}} | | category2 = {{{category|¬}}} | ||
}}x | }}x | ||
| − | x{{ | + | x{{category handler/sandbox |
| other = Somecat | | other = Somecat | ||
| page = User talk:Example/Archive 5 | | page = User talk:Example/Archive 5 | ||
| Line 595: | Line 595: | ||
<pre> | <pre> | ||
| − | x{{ | + | x{{category handler |
| 2 = Category:Somecat | | 2 = Category:Somecat | ||
| main = | | main = | ||
| Line 602: | Line 602: | ||
}}x | }}x | ||
| − | x{{ | + | x{{category handler |
| 1 = Category:Somecat | | 1 = Category:Somecat | ||
| main = | | main = | ||
| Line 609: | Line 609: | ||
}}x | }}x | ||
| − | x{{ | + | x{{category handler/sandbox |
| 1 = Category:Somecat | | 1 = Category:Somecat | ||
| main = | | main = | ||
| Line 616: | Line 616: | ||
}}x | }}x | ||
</pre> | </pre> | ||
| − | x{{ | + | x{{category handler |
| 2 = Category:Somecat | | 2 = Category:Somecat | ||
| main = | | main = | ||
| Line 623: | Line 623: | ||
}}x | }}x | ||
| − | x{{ | + | x{{category handler |
| 1 = Category:Somecat | | 1 = Category:Somecat | ||
| main = | | main = | ||
| Line 630: | Line 630: | ||
}}x | }}x | ||
| − | x{{ | + | x{{category handler/sandbox |
| 1 = Category:Somecat | | 1 = Category:Somecat | ||
| main = | | main = | ||
| Line 640: | Line 640: | ||
<pre> | <pre> | ||
| − | x{{ | + | x{{category handler/sandbox |
| all = Category:Somecat1 <!--Category for all namespaces--> | | all = Category:Somecat1 <!--Category for all namespaces--> | ||
| main = Category:Somecat2 <!--And use this in main space--> | | main = Category:Somecat2 <!--And use this in main space--> | ||
| Line 646: | Line 646: | ||
}}x | }}x | ||
| − | x{{ | + | x{{category handler/sandbox |
| all = Category:Somecat1 <!--Category for all namespaces--> | | all = Category:Somecat1 <!--Category for all namespaces--> | ||
| main = Category:Somecat2 <!--And use this in main space--> | | main = Category:Somecat2 <!--And use this in main space--> | ||
| Line 653: | Line 653: | ||
}}x | }}x | ||
| − | x{{ | + | x{{category handler/sandbox |
| all = Category:Somecat1 <!--Category for all namespaces--> | | all = Category:Somecat1 <!--Category for all namespaces--> | ||
| main = Category:Somecat2 <!--And use this in main space--> | | main = Category:Somecat2 <!--And use this in main space--> | ||
| Line 660: | Line 660: | ||
}}x | }}x | ||
</pre> | </pre> | ||
| − | x{{ | + | x{{category handler/sandbox |
| all = Category:Somecat1 <!--Category for all namespaces--> | | all = Category:Somecat1 <!--Category for all namespaces--> | ||
| main = Category:Somecat2 <!--And use this in main space--> | | main = Category:Somecat2 <!--And use this in main space--> | ||
| Line 666: | Line 666: | ||
}}x | }}x | ||
| − | x{{ | + | x{{category handler/sandbox |
| all = Category:Somecat1 <!--Category for all namespaces--> | | all = Category:Somecat1 <!--Category for all namespaces--> | ||
| main = Category:Somecat2 <!--And use this in main space--> | | main = Category:Somecat2 <!--And use this in main space--> | ||
| Line 673: | Line 673: | ||
}}x | }}x | ||
| − | x{{ | + | x{{category handler/sandbox |
| all = Category:Somecat1 <!--Category for all namespaces--> | | all = Category:Somecat1 <!--Category for all namespaces--> | ||
| main = Category:Somecat2 <!--And use this in main space--> | | main = Category:Somecat2 <!--And use this in main space--> | ||
| Line 683: | Line 683: | ||
<pre> | <pre> | ||
| − | x{{ | + | x{{category handler/sandbox |
| all = Category:Somecat1 <!--Category for all namespaces--> | | all = Category:Somecat1 <!--Category for all namespaces--> | ||
| main = Category:Somecat2 <!--And use this in main space--> | | main = Category:Somecat2 <!--And use this in main space--> | ||
| Line 690: | Line 690: | ||
}}x | }}x | ||
| − | x{{ | + | x{{category handler/sandbox |
| all = Category:Somecat1 <!--Category for all namespaces--> | | all = Category:Somecat1 <!--Category for all namespaces--> | ||
| main = Category:Somecat2 <!--And use this in main space--> | | main = Category:Somecat2 <!--And use this in main space--> | ||
| Line 698: | Line 698: | ||
}}x | }}x | ||
| − | x{{ | + | x{{category handler/sandbox |
| all = Category:Somecat1 <!--Category for all namespaces--> | | all = Category:Somecat1 <!--Category for all namespaces--> | ||
| main = Category:Somecat2 <!--And use this in main space--> | | main = Category:Somecat2 <!--And use this in main space--> | ||
| Line 706: | Line 706: | ||
}}x | }}x | ||
</pre> | </pre> | ||
| − | x{{ | + | x{{category handler/sandbox |
| all = Category:Somecat1 <!--Category for all namespaces--> | | all = Category:Somecat1 <!--Category for all namespaces--> | ||
| main = Category:Somecat2 <!--And use this in main space--> | | main = Category:Somecat2 <!--And use this in main space--> | ||
| Line 713: | Line 713: | ||
}}x | }}x | ||
| − | x{{ | + | x{{category handler/sandbox |
| all = Category:Somecat1 <!--Category for all namespaces--> | | all = Category:Somecat1 <!--Category for all namespaces--> | ||
| main = Category:Somecat2 <!--And use this in main space--> | | main = Category:Somecat2 <!--And use this in main space--> | ||
| Line 721: | Line 721: | ||
}}x | }}x | ||
| − | x{{ | + | x{{category handler/sandbox |
| all = Category:Somecat1 <!--Category for all namespaces--> | | all = Category:Somecat1 <!--Category for all namespaces--> | ||
| main = Category:Somecat2 <!--And use this in main space--> | | main = Category:Somecat2 <!--And use this in main space--> | ||
| Line 734: | Line 734: | ||
<pre> | <pre> | ||
| − | x{{ | + | x{{category handler/sandbox |
| main = Category:Somecat1 | | main = Category:Somecat1 | ||
| other = Category:Somecat2 | | other = Category:Somecat2 | ||
| Line 740: | Line 740: | ||
}}x | }}x | ||
| − | x{{ | + | x{{category handler/sandbox |
| main = Category:Somecat1 | | main = Category:Somecat1 | ||
| other = Category:Somecat2 | | other = Category:Somecat2 | ||
| Line 747: | Line 747: | ||
}}x | }}x | ||
| − | x{{ | + | x{{category handler/sandbox |
| main = Category:Somecat1 | | main = Category:Somecat1 | ||
| other = Category:Somecat2 | | other = Category:Somecat2 | ||
| Line 754: | Line 754: | ||
}}x | }}x | ||
</pre> | </pre> | ||
| − | x{{ | + | x{{category handler/sandbox |
| main = Category:Somecat1 | | main = Category:Somecat1 | ||
| other = Category:Somecat2 | | other = Category:Somecat2 | ||
| Line 760: | Line 760: | ||
}}x | }}x | ||
| − | x{{ | + | x{{category handler/sandbox |
| main = Category:Somecat1 | | main = Category:Somecat1 | ||
| other = Category:Somecat2 | | other = Category:Somecat2 | ||
| Line 767: | Line 767: | ||
}}x | }}x | ||
| − | x{{ | + | x{{category handler/sandbox |
| main = Category:Somecat1 | | main = Category:Somecat1 | ||
| other = Category:Somecat2 | | other = Category:Somecat2 | ||
| Line 777: | Line 777: | ||
<pre> | <pre> | ||
| − | x{{ | + | x{{category handler/sandbox |
| main = Category:Somecat1 | | main = Category:Somecat1 | ||
| other = Category:Somecat2 | | other = Category:Somecat2 | ||
| Line 783: | Line 783: | ||
}}x | }}x | ||
| − | x{{ | + | x{{category handler/sandbox |
| main = Category:Somecat1 | | main = Category:Somecat1 | ||
| other = Category:Somecat2 | | other = Category:Somecat2 | ||
| Line 790: | Line 790: | ||
}}x | }}x | ||
| − | x{{ | + | x{{category handler/sandbox |
| main = Category:Somecat1 | | main = Category:Somecat1 | ||
| other = Category:Somecat2 | | other = Category:Somecat2 | ||
| Line 797: | Line 797: | ||
}}x | }}x | ||
</pre> | </pre> | ||
| − | x{{ | + | x{{category handler/sandbox |
| main = Category:Somecat1 | | main = Category:Somecat1 | ||
| other = Category:Somecat2 | | other = Category:Somecat2 | ||
| Line 803: | Line 803: | ||
}}x | }}x | ||
| − | x{{ | + | x{{category handler/sandbox |
| main = Category:Somecat1 | | main = Category:Somecat1 | ||
| other = Category:Somecat2 | | other = Category:Somecat2 | ||
| Line 810: | Line 810: | ||
}}x | }}x | ||
| − | x{{ | + | x{{category handler/sandbox |
| main = Category:Somecat1 | | main = Category:Somecat1 | ||
| other = Category:Somecat2 | | other = Category:Somecat2 | ||
| Line 820: | Line 820: | ||
<pre> | <pre> | ||
| − | x{{ | + | x{{category handler |
| main = Category:Somecat1 | | main = Category:Somecat1 | ||
| other = Category:Somecat2 | | other = Category:Somecat2 | ||
| Line 827: | Line 827: | ||
}}x | }}x | ||
| − | x{{ | + | x{{category handler |
| main = Category:Somecat1 | | main = Category:Somecat1 | ||
| other = Category:Somecat2 | | other = Category:Somecat2 | ||
| Line 834: | Line 834: | ||
}}x | }}x | ||
| − | x{{ | + | x{{category handler |
| main = Category:Somecat1 | | main = Category:Somecat1 | ||
| other = Category:Somecat2 | | other = Category:Somecat2 | ||
| Line 841: | Line 841: | ||
}}x | }}x | ||
</pre> | </pre> | ||
| − | x{{ | + | x{{category handler |
| main = Category:Somecat1 | | main = Category:Somecat1 | ||
| other = Category:Somecat2 | | other = Category:Somecat2 | ||
| Line 848: | Line 848: | ||
}}x | }}x | ||
| − | x{{ | + | x{{category handler |
| main = Category:Somecat1 | | main = Category:Somecat1 | ||
| other = Category:Somecat2 | | other = Category:Somecat2 | ||
| Line 855: | Line 855: | ||
}}x | }}x | ||
| − | x{{ | + | x{{category handler |
| main = Category:Somecat1 | | main = Category:Somecat1 | ||
| other = Category:Somecat2 | | other = Category:Somecat2 | ||
Revision as of 15:32, 22 January 2012
| 42px | This is the template test cases page for the sandbox of Template:Category handler. Script error: No such module "Purge". to update the examples. If there are many examples of a complicated template, later ones may break due to limits in MediaWiki, see the HTML comment "NewPP limit report" in the rendered page. You can also use Special:ExpandTemplates to examine the results of template uses. You can test how this page looks in the different skins with these links: |
Contents
Testing {{category handler/numbered}}
x{{category handler/numbered}}x
x{{category handler/numbered
| 1 = a
| 2 = b
| 3 = c
| data = 3
}}x
x{{category handler/numbered
| 1 = a
| 2 = b
| 3 = c
| data = Somecat
}}x
x{{category handler/numbered
| 1 = a
| 2 = b
| 3 = c
| data = [[Category:Test]]
}}x
xTemplate:Category handler/numberedx
xTemplate:Category handler/numberedx
xTemplate:Category handler/numberedx
xTemplate:Category handler/numberedx
Testing {{category handler/blacklist}}
x{{category handler/blacklist}}x
x{{category handler/blacklist
| page = User talk:Example
}}x
x{{category handler/blacklist
| page = User talk:Example/Archive 5
}}x
x{{category handler/blacklist
| page = Wikipedia:Template messages/Wikipedia namespace
}}x
x-- This module contains the blacklist used by Module:Category handler. -- Pages that match Lua patterns in this list will not be categorised unless -- categorisation is explicitly requested.
return { '^Main Page$', -- don't categorise the main page.
-- Don't categorise the following pages or their subpages. -- "%f[/\0]" matches if the next character is "/" or the end of the string. '^Wikipedia:Cascade%-protected items%f[/\0]', '^User:UBX%f[/\0]', -- The userbox "template" space. '^User talk:UBX%f[/\0]',
-- Don't categorise subpages of these pages, but allow -- categorisation of the base page. '^Wikipedia:Template index/.*$',
-- Don't categorise archives. '/[aA]rchive', "^Wikipedia:Administrators' noticeboard/IncidentArchive%d+$", }x
x-- This module contains the blacklist used by Module:Category handler. -- Pages that match Lua patterns in this list will not be categorised unless -- categorisation is explicitly requested.
return { '^Main Page$', -- don't categorise the main page.
-- Don't categorise the following pages or their subpages. -- "%f[/\0]" matches if the next character is "/" or the end of the string. '^Wikipedia:Cascade%-protected items%f[/\0]', '^User:UBX%f[/\0]', -- The userbox "template" space. '^User talk:UBX%f[/\0]',
-- Don't categorise subpages of these pages, but allow -- categorisation of the base page. '^Wikipedia:Template index/.*$',
-- Don't categorise archives. '/[aA]rchive', "^Wikipedia:Administrators' noticeboard/IncidentArchive%d+$", }x
x-- This module contains the blacklist used by Module:Category handler. -- Pages that match Lua patterns in this list will not be categorised unless -- categorisation is explicitly requested.
return { '^Main Page$', -- don't categorise the main page.
-- Don't categorise the following pages or their subpages. -- "%f[/\0]" matches if the next character is "/" or the end of the string. '^Wikipedia:Cascade%-protected items%f[/\0]', '^User:UBX%f[/\0]', -- The userbox "template" space. '^User talk:UBX%f[/\0]',
-- Don't categorise subpages of these pages, but allow -- categorisation of the base page. '^Wikipedia:Template index/.*$',
-- Don't categorise archives. '/[aA]rchive', "^Wikipedia:Administrators' noticeboard/IncidentArchive%d+$", }x
x-- This module contains the blacklist used by Module:Category handler. -- Pages that match Lua patterns in this list will not be categorised unless -- categorisation is explicitly requested.
return { '^Main Page$', -- don't categorise the main page.
-- Don't categorise the following pages or their subpages. -- "%f[/\0]" matches if the next character is "/" or the end of the string. '^Wikipedia:Cascade%-protected items%f[/\0]', '^User:UBX%f[/\0]', -- The userbox "template" space. '^User talk:UBX%f[/\0]',
-- Don't categorise subpages of these pages, but allow -- categorisation of the base page. '^Wikipedia:Template index/.*$',
-- Don't categorise archives. '/[aA]rchive', "^Wikipedia:Administrators' noticeboard/IncidentArchive%d+$", }x
Testing {{category handler}}
x{{category handler}}x
x{{category handler
| Somecat
}}x
x{{category handler
| template = Somecat
}}x
x{{category handler
| Somecat
| page = Somearticle
}}x
xx
xx
xSomecatx
xSomecatx
x{{category handler
| Somecat
| page = File:Example/test
}}x
x{{category handler
| Somecat
| page = File:Example/test
| nocat =
}}x
x{{category handler
| Somecat
| page = File:Example/test
| nocat = true
}}x
xSomecatx
xSomecatx
xx
x{{category handler
| main = Category:Somecat1 Category:Somecat2
| 1 = Category:Somecat3 <!--For help, user and template space-->
| help = 1
| user = 1
| template = 1
| talk = <!--No categories on talk pages-->
| other = Category:Somecat4 <!--For all other namespaces-->
| nocat = {{{nocat|}}} <!--So "nocat=true/false" works-->
}}x
x{{category handler
| main = Category:Somecat1 Category:Somecat2
| 3 = Category:Somecat3 <!--For help, user and template space-->
| help = 3
| user = 3
| template = 3
| talk = <!--No categories on talk pages-->
| other = Category:Somecat4 <!--For all other namespaces-->
| nocat = {{{nocat|}}} <!--So "nocat=true/false" works-->
}}x
x{{category handler
| main = Category:Somecat1 Category:Somecat2
| 3 = Category:Somecat3 <!--For help, user and template space-->
| help = 3
| user = 3
| template = 3
| talk = <!--No categories on talk pages-->
| other = Category:Somecat4 <!--For all other namespaces-->
| nocat = {{{nocat|}}} <!--So "nocat=true/false" works-->
| page = Somearticle
}}x
xCategory:Somecat3x
xCategory:Somecat3x
xCategory:Somecat1 Category:Somecat2x
x{{category handler
| other = Somecat
}}x
x{{category handler
| other = Somecat
| page = User talk:Example/Archive 5
}}x
x{{category handler
| other = Somecat
| page = User talk:Example/Archive 5
| nocat = false
}}x
xSomecatx
xx
xSomecatx
x{{category handler
| other = Somecat
| categories = no
}}x
x{{category handler
| other = Somecat
| page = User talk:Example/Archive 5
| categories = yes
}}x
xx
xSomecatx
x{{category handler
| other = Somecat
| category2 = no
}}x
x{{category handler
| other = Somecat
| category2 =
}}x
x{{category handler
| other = Somecat
| category2 = ¬
}}x
x{{category handler
| other = Somecat
| category2 = {{{category|¬}}}
}}x
x{{category handler
| other = Somecat
| page = User talk:Example/Archive 5
| category2 = yes
}}x
xx
xx
xSomecatx
xSomecatx
xSomecatx
Testing {{category handler/sandbox}}
x{{category handler/sandbox}}x
x{{category handler/sandbox
| Somecat
}}x
x{{category handler/sandbox
| template = Somecat
}}x
x{{category handler/sandbox
| Somecat
| page = Somearticle
}}x
xx
xx
xSomecatx
xSomecatx
x{{category handler/sandbox
| Somecat
| page = File:Example/test
}}x
x{{category handler/sandbox
| Somecat
| page = File:Example/test
| nocat =
}}x
x{{category handler/sandbox
| Somecat
| page = File:Example/test
| nocat = true
}}x
xSomecatx
xSomecatx
xx
x{{category handler/sandbox
| main = Category:Somecat1 Category:Somecat2
| 1 = Category:Somecat3 <!--For help, user and template space-->
| help = 1
| user = 1
| template = 1
| talk = <!--No categories on talk pages-->
| other = Category:Somecat4 <!--For all other namespaces-->
| nocat = {{{nocat|}}} <!--So "nocat=true/false" works-->
}}x
x{{category handler/sandbox
| main = Category:Somecat1 Category:Somecat2
| 3 = Category:Somecat3 <!--For help, user and template space-->
| help = 3
| user = 3
| template = 3
| talk = <!--No categories on talk pages-->
| other = Category:Somecat4 <!--For all other namespaces-->
| nocat = {{{nocat|}}} <!--So "nocat=true/false" works-->
}}x
x{{category handler/sandbox
| main = Category:Somecat1 Category:Somecat2
| 3 = Category:Somecat3 <!--For help, user and template space-->
| help = 3
| user = 3
| template = 3
| talk = <!--No categories on talk pages-->
| other = Category:Somecat4 <!--For all other namespaces-->
| nocat = {{{nocat|}}} <!--So "nocat=true/false" works-->
| page = Somearticle
}}x
xCategory:Somecat3x
xCategory:Somecat3x
xCategory:Somecat1 Category:Somecat2x
x{{category handler/sandbox
| other = Somecat
}}x
x{{category handler/sandbox
| other = Somecat
| page = User talk:Example/Archive 5
}}x
x{{category handler/sandbox
| other = Somecat
| page = User talk:Example/Archive 5
| nocat = false
}}x
xSomecatx
xx
xSomecatx
x{{category handler/sandbox
| other = Somecat
| categories = no
}}x
x{{category handler/sandbox
| other = Somecat
| page = User talk:Example/Archive 5
| categories = yes
}}x
xx
xSomecatx
x{{category handler/sandbox
| other = Somecat
| category2 = no
}}x
x{{category handler/sandbox
| other = Somecat
| category2 =
}}x
x{{category handler/sandbox
| other = Somecat
| category2 = ¬
}}x
x{{category handler/sandbox
| other = Somecat
| category2 = {{{category|¬}}}
}}x
x{{category handler/sandbox
| other = Somecat
| page = User talk:Example/Archive 5
| category2 = yes
}}x
xx
xx
xSomecatx
xSomecatx
xSomecatx
Testing parameter 1
x{{category handler
| 2 = Category:Somecat
| main =
| wikipedia = 2
| page = Help:Example
}}x
x{{category handler
| 1 = Category:Somecat
| main =
| wikipedia = 1
| page = Help:Example
}}x
x{{category handler/sandbox
| 1 = Category:Somecat
| main =
| wikipedia = 1
| page = Help:Example
}}x
xx
xx
xx
Testing the "all" parameter
x{{category handler/sandbox
| all = Category:Somecat1 <!--Category for all namespaces-->
| main = Category:Somecat2 <!--And use this in main space-->
| talk = <!--But no extra category for talk pages-->
}}x
x{{category handler/sandbox
| all = Category:Somecat1 <!--Category for all namespaces-->
| main = Category:Somecat2 <!--And use this in main space-->
| talk = <!--But no extra category for talk pages-->
| page = An article
}}x
x{{category handler/sandbox
| all = Category:Somecat1 <!--Category for all namespaces-->
| main = Category:Somecat2 <!--And use this in main space-->
| talk = <!--But no extra category for talk pages-->
| page = Talk:Example
}}x
xCategory:Somecat1x
xCategory:Somecat1Category:Somecat2x
xCategory:Somecat1x
x{{category handler/sandbox
| all = Category:Somecat1 <!--Category for all namespaces-->
| main = Category:Somecat2 <!--And use this in main space-->
| other = Category:Somecat3 <!--For the rest of the namespaces-->
| talk = <!--But no extra category for talk pages-->
}}x
x{{category handler/sandbox
| all = Category:Somecat1 <!--Category for all namespaces-->
| main = Category:Somecat2 <!--And use this in main space-->
| talk = <!--But no extra category for talk pages-->
| other = Category:Somecat3 <!--For the rest of the namespaces-->
| page = An article
}}x
x{{category handler/sandbox
| all = Category:Somecat1 <!--Category for all namespaces-->
| main = Category:Somecat2 <!--And use this in main space-->
| talk = <!--But no extra category for talk pages-->
| other = Category:Somecat3 <!--For the rest of the namespaces-->
| page = Talk:Example
}}x
xCategory:Somecat1Category:Somecat3x
xCategory:Somecat1Category:Somecat2x
xCategory:Somecat1x
Testing the "subpage" parameter
x{{category handler/sandbox
| main = Category:Somecat1
| other = Category:Somecat2
| subpage = no
}}x
x{{category handler/sandbox
| main = Category:Somecat1
| other = Category:Somecat2
| subpage = no
| page = User:Example
}}x
x{{category handler/sandbox
| main = Category:Somecat1
| other = Category:Somecat2
| subpage = no
| page = User:Example/test
}}x
xx
xCategory:Somecat2x
xx
x{{category handler/sandbox
| main = Category:Somecat1
| other = Category:Somecat2
| subpage = only
}}x
x{{category handler/sandbox
| main = Category:Somecat1
| other = Category:Somecat2
| subpage = only
| page = User:Example
}}x
x{{category handler/sandbox
| main = Category:Somecat1
| other = Category:Somecat2
| subpage = only
| page = User:Example/test
}}x
xCategory:Somecat2x
xx
xCategory:Somecat2x
x{{category handler
| main = Category:Somecat1
| other = Category:Somecat2
| subpage = no
| page = User:Example
}}x
x{{category handler
| main = Category:Somecat1
| other = Category:Somecat2
| subpage = no
| page = User:Example/test
}}x
x{{category handler
| main = Category:Somecat1
| other = Category:Somecat2
| subpage = only
| page = User:Example/test
}}x
xCategory:Somecat2x
xx
xCategory:Somecat2x