Template:Category handler/testcases
{{#invoke:Message box|ombox}}
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
x{{#iferror: {{#expr: 1 + }} | | }}x
x{{#iferror: {{#expr: 1 + 3 }} | 3 | c }}x
x{{#iferror: {{#expr: 1 + Somecat }} | Somecat | }}x
x{{#iferror: {{#expr: 1 + }} | | }}x
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{{#if:x |
{{#if:{{#titleparts:{{#if:| | Template:Category handler/testcases }}|0|2}} | | }}
}}x
x{{#if:x |
{{#if:{{#titleparts:{{#if:User talk:Example| User talk:Example | Template:Category handler/testcases }}|0|2}} | | }}
}}x
x{{#if:x |
{{#if:{{#titleparts:{{#if:User talk:Example/Archive 5| User talk:Example/Archive 5 | Template:Category handler/testcases }}|0|2}} | | }}
}}x
x{{#if:x |
{{#if:{{#titleparts:{{#if:Wikipedia:Template messages/Wikipedia namespace| Wikipedia:Template messages/Wikipedia namespace | Template:Category handler/testcases }}|0|2}} | | }}
}}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
x{{#if:
{{#ifeq: | true | dontcat }}{{#ifeq: | no | dontcat }}{{#switch: ¬ | yes | ¬ = | #default = dontcat }}{{#switch: | no = {{#switch: {{#if: | {{#if:{{#titleparts:|0|3}} | subsubpage | {{#if:{{#titleparts:|0|2}} | subpage | basepage }} }} | {{#if:{{#titleparts:Template:Category handler/testcases|0|3}} | subsubpage | {{#if:{{#titleparts:Template:Category handler/testcases|0|2}} | subpage | basepage }} }} }}
| basepage =
| subpage = dontcat
| subsubpage = dontcat
}}
| only = {{#switch: {{#if: | {{#if:{{#titleparts:|0|3}} | subsubpage | {{#if:{{#titleparts:|0|2}} | subpage | basepage }} }} | {{#if:{{#titleparts:Template:Category handler/testcases|0|3}} | subsubpage | {{#if:{{#titleparts:Template:Category handler/testcases|0|2}} | subpage | basepage }} }} }}
| basepage = dontcat
| subpage = | subsubpage = }}
}}
| |
{{#switch: {{#ifeq: | false | | {{#ifeq: | yes | | {{#ifeq: | yes | | {{#if:x
|
{{#if:{{#titleparts:{{#if:| | Template:Category handler/testcases }}|0|2}} | | }}
}}
}} }} }} | hide = | #default = {{#ifeq: h0#384!5nea+w9 | h0#384!5nea+w9 | {{#invoke:Namespace detect|main}} | {{#iferror: {{#expr: 1 + {{#invoke:Namespace detect|main}} }}
| {{#invoke:Namespace detect|main}} | }}
}} }}
}}x
x{{#if:
{{#ifeq: | true | dontcat }}{{#ifeq: | no | dontcat }}{{#switch: ¬ | yes | ¬ = | #default = dontcat }}{{#switch: | no = {{#switch: {{#if: | {{#if:{{#titleparts:|0|3}} | subsubpage | {{#if:{{#titleparts:|0|2}} | subpage | basepage }} }} | {{#if:{{#titleparts:Template:Category handler/testcases|0|3}} | subsubpage | {{#if:{{#titleparts:Template:Category handler/testcases|0|2}} | subpage | basepage }} }} }}
| basepage =
| subpage = dontcat
| subsubpage = dontcat
}}
| only = {{#switch: {{#if: | {{#if:{{#titleparts:|0|3}} | subsubpage | {{#if:{{#titleparts:|0|2}} | subpage | basepage }} }} | {{#if:{{#titleparts:Template:Category handler/testcases|0|3}} | subsubpage | {{#if:{{#titleparts:Template:Category handler/testcases|0|2}} | subpage | basepage }} }} }}
| basepage = dontcat
| subpage = | subsubpage = }}
}}
| |
{{#switch: {{#ifeq: | false | | {{#ifeq: | yes | | {{#ifeq: | yes | | {{#if:x
|
{{#if:{{#titleparts:{{#if:| | Template:Category handler/testcases }}|0|2}} | | }}
}}
}} }} }} | hide = | #default = {{#ifeq: h0#384!5nea+w9 | h0#384!5nea+w9 | {{#invoke:Namespace detect|main}} | {{#iferror: {{#expr: 1 + {{#invoke:Namespace detect|main}} }}
| {{#invoke:Namespace detect|main}} | }}
}} }}
}}x
x{{#if:
{{#ifeq: | true | dontcat }}{{#ifeq: | no | dontcat }}{{#switch: ¬ | yes | ¬ = | #default = dontcat }}{{#switch: | no = {{#switch: {{#if: | {{#if:{{#titleparts:|0|3}} | subsubpage | {{#if:{{#titleparts:|0|2}} | subpage | basepage }} }} | {{#if:{{#titleparts:Template:Category handler/testcases|0|3}} | subsubpage | {{#if:{{#titleparts:Template:Category handler/testcases|0|2}} | subpage | basepage }} }} }}
| basepage =
| subpage = dontcat
| subsubpage = dontcat
}}
| only = {{#switch: {{#if: | {{#if:{{#titleparts:|0|3}} | subsubpage | {{#if:{{#titleparts:|0|2}} | subpage | basepage }} }} | {{#if:{{#titleparts:Template:Category handler/testcases|0|3}} | subsubpage | {{#if:{{#titleparts:Template:Category handler/testcases|0|2}} | subpage | basepage }} }} }}
| basepage = dontcat
| subpage = | subsubpage = }}
}}
| |
{{#switch: {{#ifeq: | false | | {{#ifeq: | yes | | {{#ifeq: | yes | | {{#if:x
|
{{#if:{{#titleparts:{{#if:| | Template:Category handler/testcases }}|0|2}} | | }}
}}
}} }} }} | hide = | #default = {{#ifeq: h0#384!5nea+w9 | Somecat | {{#invoke:Namespace detect|main}} | {{#iferror: {{#expr: 1 + {{#invoke:Namespace detect|main}} }}
| {{#invoke:Namespace detect|main}} | }}
}} }}
}}x
x{{#if:
{{#ifeq: | true | dontcat }}{{#ifeq: | no | dontcat }}{{#switch: ¬ | yes | ¬ = | #default = dontcat }}{{#switch: | no = {{#switch: {{#if:Somearticle | {{#if:{{#titleparts:Somearticle|0|3}} | subsubpage | {{#if:{{#titleparts:Somearticle|0|2}} | subpage | basepage }} }} | {{#if:{{#titleparts:Template:Category handler/testcases|0|3}} | subsubpage | {{#if:{{#titleparts:Template:Category handler/testcases|0|2}} | subpage | basepage }} }} }}
| basepage =
| subpage = dontcat
| subsubpage = dontcat
}}
| only = {{#switch: {{#if:Somearticle | {{#if:{{#titleparts:Somearticle|0|3}} | subsubpage | {{#if:{{#titleparts:Somearticle|0|2}} | subpage | basepage }} }} | {{#if:{{#titleparts:Template:Category handler/testcases|0|3}} | subsubpage | {{#if:{{#titleparts:Template:Category handler/testcases|0|2}} | subpage | basepage }} }} }}
| basepage = dontcat
| subpage = | subsubpage = }}
}}
| |
{{#switch: {{#ifeq: | false | | {{#ifeq: | yes | | {{#ifeq: | yes | | {{#if:x
|
{{#if:{{#titleparts:{{#if:Somearticle| Somearticle | Template:Category handler/testcases }}|0|2}} | | }}
}}
}} }} }} | hide = | #default = {{#ifeq: h0#384!5nea+w9 | h0#384!5nea+w9 | {{#invoke:Namespace detect|main}} | {{#iferror: {{#expr: 1 + {{#invoke:Namespace detect|main}} }}
| {{#invoke:Namespace detect|main}} | }}
}} }}
}}x
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
x{{#if:
{{#ifeq: | true | dontcat }}{{#ifeq: | no | dontcat }}{{#switch: ¬ | yes | ¬ = | #default = dontcat }}{{#switch: | no = {{#switch: {{#if:File:Example/test | {{#if:{{#titleparts:File:Example/test|0|3}} | subsubpage | {{#if:{{#titleparts:File:Example/test|0|2}} | subpage | basepage }} }} | {{#if:{{#titleparts:Template:Category handler/testcases|0|3}} | subsubpage | {{#if:{{#titleparts:Template:Category handler/testcases|0|2}} | subpage | basepage }} }} }}
| basepage =
| subpage = dontcat
| subsubpage = dontcat
}}
| only = {{#switch: {{#if:File:Example/test | {{#if:{{#titleparts:File:Example/test|0|3}} | subsubpage | {{#if:{{#titleparts:File:Example/test|0|2}} | subpage | basepage }} }} | {{#if:{{#titleparts:Template:Category handler/testcases|0|3}} | subsubpage | {{#if:{{#titleparts:Template:Category handler/testcases|0|2}} | subpage | basepage }} }} }}
| basepage = dontcat
| subpage = | subsubpage = }}
}}
| |
{{#switch: {{#ifeq: | false | | {{#ifeq: | yes | | {{#ifeq: | yes | | {{#if:x
|
{{#if:{{#titleparts:{{#if:File:Example/test| File:Example/test | Template:Category handler/testcases }}|0|2}} | | }}
}}
}} }} }} | hide = | #default = {{#ifeq: h0#384!5nea+w9 | h0#384!5nea+w9 | {{#invoke:Namespace detect|main}} | {{#iferror: {{#expr: 1 + {{#invoke:Namespace detect|main}} }}
| {{#invoke:Namespace detect|main}} | }}
}} }}
}}x
x{{#if:
{{#ifeq: | true | dontcat }}{{#ifeq: | no | dontcat }}{{#switch: ¬ | yes | ¬ = | #default = dontcat }}{{#switch: | no = {{#switch: {{#if:File:Example/test | {{#if:{{#titleparts:File:Example/test|0|3}} | subsubpage | {{#if:{{#titleparts:File:Example/test|0|2}} | subpage | basepage }} }} | {{#if:{{#titleparts:Template:Category handler/testcases|0|3}} | subsubpage | {{#if:{{#titleparts:Template:Category handler/testcases|0|2}} | subpage | basepage }} }} }}
| basepage =
| subpage = dontcat
| subsubpage = dontcat
}}
| only = {{#switch: {{#if:File:Example/test | {{#if:{{#titleparts:File:Example/test|0|3}} | subsubpage | {{#if:{{#titleparts:File:Example/test|0|2}} | subpage | basepage }} }} | {{#if:{{#titleparts:Template:Category handler/testcases|0|3}} | subsubpage | {{#if:{{#titleparts:Template:Category handler/testcases|0|2}} | subpage | basepage }} }} }}
| basepage = dontcat
| subpage = | subsubpage = }}
}}
| |
{{#switch: {{#ifeq: | false | | {{#ifeq: | yes | | {{#ifeq: | yes | | {{#if:x
|
{{#if:{{#titleparts:{{#if:File:Example/test| File:Example/test | Template:Category handler/testcases }}|0|2}} | | }}
}}
}} }} }} | hide = | #default = {{#ifeq: h0#384!5nea+w9 | h0#384!5nea+w9 | {{#invoke:Namespace detect|main}} | {{#iferror: {{#expr: 1 + {{#invoke:Namespace detect|main}} }}
| {{#invoke:Namespace detect|main}} | }}
}} }}
}}x
x{{#if:
{{#ifeq: true | true | dontcat }}{{#ifeq: | no | dontcat }}{{#switch: ¬ | yes | ¬ = | #default = dontcat }}{{#switch: | no = {{#switch: {{#if:File:Example/test | {{#if:{{#titleparts:File:Example/test|0|3}} | subsubpage | {{#if:{{#titleparts:File:Example/test|0|2}} | subpage | basepage }} }} | {{#if:{{#titleparts:Template:Category handler/testcases|0|3}} | subsubpage | {{#if:{{#titleparts:Template:Category handler/testcases|0|2}} | subpage | basepage }} }} }}
| basepage =
| subpage = dontcat
| subsubpage = dontcat
}}
| only = {{#switch: {{#if:File:Example/test | {{#if:{{#titleparts:File:Example/test|0|3}} | subsubpage | {{#if:{{#titleparts:File:Example/test|0|2}} | subpage | basepage }} }} | {{#if:{{#titleparts:Template:Category handler/testcases|0|3}} | subsubpage | {{#if:{{#titleparts:Template:Category handler/testcases|0|2}} | subpage | basepage }} }} }}
| basepage = dontcat
| subpage = | subsubpage = }}
}}
| |
{{#switch: {{#ifeq: true | false | | {{#ifeq: | yes | | {{#ifeq: | yes | | {{#if:x
|
{{#if:{{#titleparts:{{#if:File:Example/test| File:Example/test | Template:Category handler/testcases }}|0|2}} | | }}
}}
}} }} }} | hide = | #default = {{#ifeq: h0#384!5nea+w9 | h0#384!5nea+w9 | {{#invoke:Namespace detect|main}} | {{#iferror: {{#expr: 1 + {{#invoke:Namespace detect|main}} }}
| {{#invoke:Namespace detect|main}} | }}
}} }}
}}x
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
x{{#if:
{{#ifeq: | true | dontcat }}{{#ifeq: | no | dontcat }}{{#switch: ¬ | yes | ¬ = | #default = dontcat }}{{#switch: | no = {{#switch: {{#if: | {{#if:{{#titleparts:|0|3}} | subsubpage | {{#if:{{#titleparts:|0|2}} | subpage | basepage }} }} | {{#if:{{#titleparts:Template:Category handler/testcases|0|3}} | subsubpage | {{#if:{{#titleparts:Template:Category handler/testcases|0|2}} | subpage | basepage }} }} }}
| basepage =
| subpage = dontcat
| subsubpage = dontcat
}}
| only = {{#switch: {{#if: | {{#if:{{#titleparts:|0|3}} | subsubpage | {{#if:{{#titleparts:|0|2}} | subpage | basepage }} }} | {{#if:{{#titleparts:Template:Category handler/testcases|0|3}} | subsubpage | {{#if:{{#titleparts:Template:Category handler/testcases|0|2}} | subpage | basepage }} }} }}
| basepage = dontcat
| subpage = | subsubpage = }}
}}
| |
{{#switch: {{#ifeq: | false | | {{#ifeq: | yes | | {{#ifeq: | yes | | {{#if:x
|
{{#if:{{#titleparts:{{#if:| | Template:Category handler/testcases }}|0|2}} | | }}
}}
}} }} }} | hide = | #default = {{#ifeq: h0#384!5nea+w9 | Category:Somecat1 Category:Somecat2 | {{#invoke:Namespace detect|main}} | {{#iferror: {{#expr: 1 + {{#invoke:Namespace detect|main}} }}
| {{#invoke:Namespace detect|main}} | }}
}} }}
}}x
x{{#if:
{{#ifeq: | true | dontcat }}{{#ifeq: | no | dontcat }}{{#switch: ¬ | yes | ¬ = | #default = dontcat }}{{#switch: | no = {{#switch: {{#if: | {{#if:{{#titleparts:|0|3}} | subsubpage | {{#if:{{#titleparts:|0|2}} | subpage | basepage }} }} | {{#if:{{#titleparts:Template:Category handler/testcases|0|3}} | subsubpage | {{#if:{{#titleparts:Template:Category handler/testcases|0|2}} | subpage | basepage }} }} }}
| basepage =
| subpage = dontcat
| subsubpage = dontcat
}}
| only = {{#switch: {{#if: | {{#if:{{#titleparts:|0|3}} | subsubpage | {{#if:{{#titleparts:|0|2}} | subpage | basepage }} }} | {{#if:{{#titleparts:Template:Category handler/testcases|0|3}} | subsubpage | {{#if:{{#titleparts:Template:Category handler/testcases|0|2}} | subpage | basepage }} }} }}
| basepage = dontcat
| subpage = | subsubpage = }}
}}
| |
{{#switch: {{#ifeq: | false | | {{#ifeq: | yes | | {{#ifeq: | yes | | {{#if:x
|
{{#if:{{#titleparts:{{#if:| | Template:Category handler/testcases }}|0|2}} | | }}
}}
}} }} }} | hide = | #default = {{#ifeq: h0#384!5nea+w9 | Category:Somecat1 Category:Somecat2 | {{#invoke:Namespace detect|main}} | {{#iferror: {{#expr: 1 + {{#invoke:Namespace detect|main}} }}
| {{#invoke:Namespace detect|main}} | }}
}} }}
}}x
x{{#if:
{{#ifeq: | true | dontcat }}{{#ifeq: | no | dontcat }}{{#switch: ¬ | yes | ¬ = | #default = dontcat }}{{#switch: | no = {{#switch: {{#if:Somearticle | {{#if:{{#titleparts:Somearticle|0|3}} | subsubpage | {{#if:{{#titleparts:Somearticle|0|2}} | subpage | basepage }} }} | {{#if:{{#titleparts:Template:Category handler/testcases|0|3}} | subsubpage | {{#if:{{#titleparts:Template:Category handler/testcases|0|2}} | subpage | basepage }} }} }}
| basepage =
| subpage = dontcat
| subsubpage = dontcat
}}
| only = {{#switch: {{#if:Somearticle | {{#if:{{#titleparts:Somearticle|0|3}} | subsubpage | {{#if:{{#titleparts:Somearticle|0|2}} | subpage | basepage }} }} | {{#if:{{#titleparts:Template:Category handler/testcases|0|3}} | subsubpage | {{#if:{{#titleparts:Template:Category handler/testcases|0|2}} | subpage | basepage }} }} }}
| basepage = dontcat
| subpage = | subsubpage = }}
}}
| |
{{#switch: {{#ifeq: | false | | {{#ifeq: | yes | | {{#ifeq: | yes | | {{#if:x
|
{{#if:{{#titleparts:{{#if:Somearticle| Somearticle | Template:Category handler/testcases }}|0|2}} | | }}
}}
}} }} }} | hide = | #default = {{#ifeq: h0#384!5nea+w9 | Category:Somecat1 Category:Somecat2 | {{#invoke:Namespace detect|main}} | {{#iferror: {{#expr: 1 + {{#invoke:Namespace detect|main}} }}
| {{#invoke:Namespace detect|main}} | }}
}} }}
}}x
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
x{{#if:
{{#ifeq: | true | dontcat }}{{#ifeq: | no | dontcat }}{{#switch: ¬ | yes | ¬ = | #default = dontcat }}{{#switch: | no = {{#switch: {{#if: | {{#if:{{#titleparts:|0|3}} | subsubpage | {{#if:{{#titleparts:|0|2}} | subpage | basepage }} }} | {{#if:{{#titleparts:Template:Category handler/testcases|0|3}} | subsubpage | {{#if:{{#titleparts:Template:Category handler/testcases|0|2}} | subpage | basepage }} }} }}
| basepage =
| subpage = dontcat
| subsubpage = dontcat
}}
| only = {{#switch: {{#if: | {{#if:{{#titleparts:|0|3}} | subsubpage | {{#if:{{#titleparts:|0|2}} | subpage | basepage }} }} | {{#if:{{#titleparts:Template:Category handler/testcases|0|3}} | subsubpage | {{#if:{{#titleparts:Template:Category handler/testcases|0|2}} | subpage | basepage }} }} }}
| basepage = dontcat
| subpage = | subsubpage = }}
}}
| |
{{#switch: {{#ifeq: | false | | {{#ifeq: | yes | | {{#ifeq: | yes | | {{#if:x
|
{{#if:{{#titleparts:{{#if:| | Template:Category handler/testcases }}|0|2}} | | }}
}}
}} }} }} | hide = | #default = {{#ifeq: h0#384!5nea+w9 | Somecat | {{#invoke:Namespace detect|main}} | {{#iferror: {{#expr: 1 + {{#invoke:Namespace detect|main}} }}
| {{#invoke:Namespace detect|main}} | }}
}} }}
}}x
x{{#if:
{{#ifeq: | true | dontcat }}{{#ifeq: | no | dontcat }}{{#switch: ¬ | yes | ¬ = | #default = dontcat }}{{#switch: | no = {{#switch: {{#if:User talk:Example/Archive 5 | {{#if:{{#titleparts:User talk:Example/Archive 5|0|3}} | subsubpage | {{#if:{{#titleparts:User talk:Example/Archive 5|0|2}} | subpage | basepage }} }} | {{#if:{{#titleparts:Template:Category handler/testcases|0|3}} | subsubpage | {{#if:{{#titleparts:Template:Category handler/testcases|0|2}} | subpage | basepage }} }} }}
| basepage =
| subpage = dontcat
| subsubpage = dontcat
}}
| only = {{#switch: {{#if:User talk:Example/Archive 5 | {{#if:{{#titleparts:User talk:Example/Archive 5|0|3}} | subsubpage | {{#if:{{#titleparts:User talk:Example/Archive 5|0|2}} | subpage | basepage }} }} | {{#if:{{#titleparts:Template:Category handler/testcases|0|3}} | subsubpage | {{#if:{{#titleparts:Template:Category handler/testcases|0|2}} | subpage | basepage }} }} }}
| basepage = dontcat
| subpage = | subsubpage = }}
}}
| |
{{#switch: {{#ifeq: | false | | {{#ifeq: | yes | | {{#ifeq: | yes | | {{#if:x
|
{{#if:{{#titleparts:{{#if:User talk:Example/Archive 5| User talk:Example/Archive 5 | Template:Category handler/testcases }}|0|2}} | | }}
}}
}} }} }} | hide = | #default = {{#ifeq: h0#384!5nea+w9 | Somecat | {{#invoke:Namespace detect|main}} | {{#iferror: {{#expr: 1 + {{#invoke:Namespace detect|main}} }}
| {{#invoke:Namespace detect|main}} | }}
}} }}
}}x
x{{#if:
{{#ifeq: false | true | dontcat }}{{#ifeq: | no | dontcat }}{{#switch: ¬ | yes | ¬ = | #default = dontcat }}{{#switch: | no = {{#switch: {{#if:User talk:Example/Archive 5 | {{#if:{{#titleparts:User talk:Example/Archive 5|0|3}} | subsubpage | {{#if:{{#titleparts:User talk:Example/Archive 5|0|2}} | subpage | basepage }} }} | {{#if:{{#titleparts:Template:Category handler/testcases|0|3}} | subsubpage | {{#if:{{#titleparts:Template:Category handler/testcases|0|2}} | subpage | basepage }} }} }}
| basepage =
| subpage = dontcat
| subsubpage = dontcat
}}
| only = {{#switch: {{#if:User talk:Example/Archive 5 | {{#if:{{#titleparts:User talk:Example/Archive 5|0|3}} | subsubpage | {{#if:{{#titleparts:User talk:Example/Archive 5|0|2}} | subpage | basepage }} }} | {{#if:{{#titleparts:Template:Category handler/testcases|0|3}} | subsubpage | {{#if:{{#titleparts:Template:Category handler/testcases|0|2}} | subpage | basepage }} }} }}
| basepage = dontcat
| subpage = | subsubpage = }}
}}
| |
{{#switch: {{#ifeq: false | false | | {{#ifeq: | yes | | {{#ifeq: | yes | | {{#if:x
|
{{#if:{{#titleparts:{{#if:User talk:Example/Archive 5| User talk:Example/Archive 5 | Template:Category handler/testcases }}|0|2}} | | }}
}}
}} }} }} | hide = | #default = {{#ifeq: h0#384!5nea+w9 | Somecat | {{#invoke:Namespace detect|main}} | {{#iferror: {{#expr: 1 + {{#invoke:Namespace detect|main}} }}
| {{#invoke:Namespace detect|main}} | }}
}} }}
}}x
x{{category handler | other = Somecat | categories = no }}x x{{category handler | other = Somecat | page = User talk:Example/Archive 5 | categories = yes }}x
x{{#if:
{{#ifeq: | true | dontcat }}{{#ifeq: no | no | dontcat }}{{#switch: ¬ | yes | ¬ = | #default = dontcat }}{{#switch: | no = {{#switch: {{#if: | {{#if:{{#titleparts:|0|3}} | subsubpage | {{#if:{{#titleparts:|0|2}} | subpage | basepage }} }} | {{#if:{{#titleparts:Template:Category handler/testcases|0|3}} | subsubpage | {{#if:{{#titleparts:Template:Category handler/testcases|0|2}} | subpage | basepage }} }} }}
| basepage =
| subpage = dontcat
| subsubpage = dontcat
}}
| only = {{#switch: {{#if: | {{#if:{{#titleparts:|0|3}} | subsubpage | {{#if:{{#titleparts:|0|2}} | subpage | basepage }} }} | {{#if:{{#titleparts:Template:Category handler/testcases|0|3}} | subsubpage | {{#if:{{#titleparts:Template:Category handler/testcases|0|2}} | subpage | basepage }} }} }}
| basepage = dontcat
| subpage = | subsubpage = }}
}}
| |
{{#switch: {{#ifeq: | false | | {{#ifeq: no | yes | | {{#ifeq: | yes | | {{#if:x
|
{{#if:{{#titleparts:{{#if:| | Template:Category handler/testcases }}|0|2}} | | }}
}}
}} }} }} | hide = | #default = {{#ifeq: h0#384!5nea+w9 | Somecat | {{#invoke:Namespace detect|main}} | {{#iferror: {{#expr: 1 + {{#invoke:Namespace detect|main}} }}
| {{#invoke:Namespace detect|main}} | }}
}} }}
}}x
x{{#if:
{{#ifeq: | true | dontcat }}{{#ifeq: yes | no | dontcat }}{{#switch: ¬ | yes | ¬ = | #default = dontcat }}{{#switch: | no = {{#switch: {{#if:User talk:Example/Archive 5 | {{#if:{{#titleparts:User talk:Example/Archive 5|0|3}} | subsubpage | {{#if:{{#titleparts:User talk:Example/Archive 5|0|2}} | subpage | basepage }} }} | {{#if:{{#titleparts:Template:Category handler/testcases|0|3}} | subsubpage | {{#if:{{#titleparts:Template:Category handler/testcases|0|2}} | subpage | basepage }} }} }}
| basepage =
| subpage = dontcat
| subsubpage = dontcat
}}
| only = {{#switch: {{#if:User talk:Example/Archive 5 | {{#if:{{#titleparts:User talk:Example/Archive 5|0|3}} | subsubpage | {{#if:{{#titleparts:User talk:Example/Archive 5|0|2}} | subpage | basepage }} }} | {{#if:{{#titleparts:Template:Category handler/testcases|0|3}} | subsubpage | {{#if:{{#titleparts:Template:Category handler/testcases|0|2}} | subpage | basepage }} }} }}
| basepage = dontcat
| subpage = | subsubpage = }}
}}
| |
{{#switch: {{#ifeq: | false | | {{#ifeq: yes | yes | | {{#ifeq: | yes | | {{#if:x
|
{{#if:{{#titleparts:{{#if:User talk:Example/Archive 5| User talk:Example/Archive 5 | Template:Category handler/testcases }}|0|2}} | | }}
}}
}} }} }} | hide = | #default = {{#ifeq: h0#384!5nea+w9 | Somecat | {{#invoke:Namespace detect|main}} | {{#iferror: {{#expr: 1 + {{#invoke:Namespace detect|main}} }}
| {{#invoke:Namespace detect|main}} | }}
}} }}
}}x
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
x{{#if:
{{#ifeq: | true | dontcat }}{{#ifeq: | no | dontcat }}{{#switch: no | yes | ¬ = | #default = dontcat }}{{#switch: | no = {{#switch: {{#if: | {{#if:{{#titleparts:|0|3}} | subsubpage | {{#if:{{#titleparts:|0|2}} | subpage | basepage }} }} | {{#if:{{#titleparts:Template:Category handler/testcases|0|3}} | subsubpage | {{#if:{{#titleparts:Template:Category handler/testcases|0|2}} | subpage | basepage }} }} }}
| basepage =
| subpage = dontcat
| subsubpage = dontcat
}}
| only = {{#switch: {{#if: | {{#if:{{#titleparts:|0|3}} | subsubpage | {{#if:{{#titleparts:|0|2}} | subpage | basepage }} }} | {{#if:{{#titleparts:Template:Category handler/testcases|0|3}} | subsubpage | {{#if:{{#titleparts:Template:Category handler/testcases|0|2}} | subpage | basepage }} }} }}
| basepage = dontcat
| subpage = | subsubpage = }}
}}
| |
{{#switch: {{#ifeq: | false | | {{#ifeq: | yes | | {{#ifeq: no | yes | | {{#if:x
|
{{#if:{{#titleparts:{{#if:| | Template:Category handler/testcases }}|0|2}} | | }}
}}
}} }} }} | hide = | #default = {{#ifeq: h0#384!5nea+w9 | Somecat | {{#invoke:Namespace detect|main}} | {{#iferror: {{#expr: 1 + {{#invoke:Namespace detect|main}} }}
| {{#invoke:Namespace detect|main}} | }}
}} }}
}}x
x{{#if:
{{#ifeq: | true | dontcat }}{{#ifeq: | no | dontcat }}{{#switch: | yes | ¬ = | #default = dontcat }}{{#switch: | no = {{#switch: {{#if: | {{#if:{{#titleparts:|0|3}} | subsubpage | {{#if:{{#titleparts:|0|2}} | subpage | basepage }} }} | {{#if:{{#titleparts:Template:Category handler/testcases|0|3}} | subsubpage | {{#if:{{#titleparts:Template:Category handler/testcases|0|2}} | subpage | basepage }} }} }}
| basepage =
| subpage = dontcat
| subsubpage = dontcat
}}
| only = {{#switch: {{#if: | {{#if:{{#titleparts:|0|3}} | subsubpage | {{#if:{{#titleparts:|0|2}} | subpage | basepage }} }} | {{#if:{{#titleparts:Template:Category handler/testcases|0|3}} | subsubpage | {{#if:{{#titleparts:Template:Category handler/testcases|0|2}} | subpage | basepage }} }} }}
| basepage = dontcat
| subpage = | subsubpage = }}
}}
| |
{{#switch: {{#ifeq: | false | | {{#ifeq: | yes | | {{#ifeq: | yes | | {{#if:x
|
{{#if:{{#titleparts:{{#if:| | Template:Category handler/testcases }}|0|2}} | | }}
}}
}} }} }} | hide = | #default = {{#ifeq: h0#384!5nea+w9 | Somecat | {{#invoke:Namespace detect|main}} | {{#iferror: {{#expr: 1 + {{#invoke:Namespace detect|main}} }}
| {{#invoke:Namespace detect|main}} | }}
}} }}
}}x
x{{#if:
{{#ifeq: | true | dontcat }}{{#ifeq: | no | dontcat }}{{#switch: ¬ | yes | ¬ = | #default = dontcat }}{{#switch: | no = {{#switch: {{#if: | {{#if:{{#titleparts:|0|3}} | subsubpage | {{#if:{{#titleparts:|0|2}} | subpage | basepage }} }} | {{#if:{{#titleparts:Template:Category handler/testcases|0|3}} | subsubpage | {{#if:{{#titleparts:Template:Category handler/testcases|0|2}} | subpage | basepage }} }} }}
| basepage =
| subpage = dontcat
| subsubpage = dontcat
}}
| only = {{#switch: {{#if: | {{#if:{{#titleparts:|0|3}} | subsubpage | {{#if:{{#titleparts:|0|2}} | subpage | basepage }} }} | {{#if:{{#titleparts:Template:Category handler/testcases|0|3}} | subsubpage | {{#if:{{#titleparts:Template:Category handler/testcases|0|2}} | subpage | basepage }} }} }}
| basepage = dontcat
| subpage = | subsubpage = }}
}}
| |
{{#switch: {{#ifeq: | false | | {{#ifeq: | yes | | {{#ifeq: ¬ | yes | | {{#if:x
|
{{#if:{{#titleparts:{{#if:| | Template:Category handler/testcases }}|0|2}} | | }}
}}
}} }} }} | hide = | #default = {{#ifeq: h0#384!5nea+w9 | Somecat | {{#invoke:Namespace detect|main}} | {{#iferror: {{#expr: 1 + {{#invoke:Namespace detect|main}} }}
| {{#invoke:Namespace detect|main}} | }}
}} }}
}}x
x{{#if:
{{#ifeq: | true | dontcat }}{{#ifeq: | no | dontcat }}{{#switch: ¬ | yes | ¬ = | #default = dontcat }}{{#switch: | no = {{#switch: {{#if: | {{#if:{{#titleparts:|0|3}} | subsubpage | {{#if:{{#titleparts:|0|2}} | subpage | basepage }} }} | {{#if:{{#titleparts:Template:Category handler/testcases|0|3}} | subsubpage | {{#if:{{#titleparts:Template:Category handler/testcases|0|2}} | subpage | basepage }} }} }}
| basepage =
| subpage = dontcat
| subsubpage = dontcat
}}
| only = {{#switch: {{#if: | {{#if:{{#titleparts:|0|3}} | subsubpage | {{#if:{{#titleparts:|0|2}} | subpage | basepage }} }} | {{#if:{{#titleparts:Template:Category handler/testcases|0|3}} | subsubpage | {{#if:{{#titleparts:Template:Category handler/testcases|0|2}} | subpage | basepage }} }} }}
| basepage = dontcat
| subpage = | subsubpage = }}
}}
| |
{{#switch: {{#ifeq: | false | | {{#ifeq: | yes | | {{#ifeq: ¬ | yes | | {{#if:x
|
{{#if:{{#titleparts:{{#if:| | Template:Category handler/testcases }}|0|2}} | | }}
}}
}} }} }} | hide = | #default = {{#ifeq: h0#384!5nea+w9 | Somecat | {{#invoke:Namespace detect|main}} | {{#iferror: {{#expr: 1 + {{#invoke:Namespace detect|main}} }}
| {{#invoke:Namespace detect|main}} | }}
}} }}
}}x
x{{#if:
{{#ifeq: | true | dontcat }}{{#ifeq: | no | dontcat }}{{#switch: yes | yes | ¬ = | #default = dontcat }}{{#switch: | no = {{#switch: {{#if:User talk:Example/Archive 5 | {{#if:{{#titleparts:User talk:Example/Archive 5|0|3}} | subsubpage | {{#if:{{#titleparts:User talk:Example/Archive 5|0|2}} | subpage | basepage }} }} | {{#if:{{#titleparts:Template:Category handler/testcases|0|3}} | subsubpage | {{#if:{{#titleparts:Template:Category handler/testcases|0|2}} | subpage | basepage }} }} }}
| basepage =
| subpage = dontcat
| subsubpage = dontcat
}}
| only = {{#switch: {{#if:User talk:Example/Archive 5 | {{#if:{{#titleparts:User talk:Example/Archive 5|0|3}} | subsubpage | {{#if:{{#titleparts:User talk:Example/Archive 5|0|2}} | subpage | basepage }} }} | {{#if:{{#titleparts:Template:Category handler/testcases|0|3}} | subsubpage | {{#if:{{#titleparts:Template:Category handler/testcases|0|2}} | subpage | basepage }} }} }}
| basepage = dontcat
| subpage = | subsubpage = }}
}}
| |
{{#switch: {{#ifeq: | false | | {{#ifeq: | yes | | {{#ifeq: yes | yes | | {{#if:x
|
{{#if:{{#titleparts:{{#if:User talk:Example/Archive 5| User talk:Example/Archive 5 | Template:Category handler/testcases }}|0|2}} | | }}
}}
}} }} }} | hide = | #default = {{#ifeq: h0#384!5nea+w9 | Somecat | {{#invoke:Namespace detect|main}} | {{#iferror: {{#expr: 1 + {{#invoke:Namespace detect|main}} }}
| {{#invoke:Namespace detect|main}} | }}
}} }}
}}x
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
x{{#invoke:Category handler|main}}x
x{{#invoke:Category handler|main}}x
x{{#invoke:Category handler|main}}x
x{{#invoke:Category handler|main}}x
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
x{{#invoke:Category handler|main}}x
x{{#invoke:Category handler|main}}x
x{{#invoke:Category handler|main}}x
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
x{{#invoke:Category handler|main}}x
x{{#invoke:Category handler|main}}x
x{{#invoke:Category handler|main}}x
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
x{{#invoke:Category handler|main}}x
x{{#invoke:Category handler|main}}x
x{{#invoke:Category handler|main}}x
x{{category handler/sandbox | other = Somecat | categories = no }}x x{{category handler/sandbox | other = Somecat | page = User talk:Example/Archive 5 | categories = yes }}x
x{{#invoke:Category handler|main}}x
x{{#invoke:Category handler|main}}x
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
x{{#invoke:Category handler|main}}x
x{{#invoke:Category handler|main}}x
x{{#invoke:Category handler|main}}x
x{{#invoke:Category handler|main}}x
x{{#invoke:Category handler|main}}x
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
x{{#if:
{{#ifeq: | true | dontcat }}{{#ifeq: | no | dontcat }}{{#switch: ¬ | yes | ¬ = | #default = dontcat }}{{#switch: | no = {{#switch: {{#if:Help:Example | {{#if:{{#titleparts:Help:Example|0|3}} | subsubpage | {{#if:{{#titleparts:Help:Example|0|2}} | subpage | basepage }} }} | {{#if:{{#titleparts:Template:Category handler/testcases|0|3}} | subsubpage | {{#if:{{#titleparts:Template:Category handler/testcases|0|2}} | subpage | basepage }} }} }}
| basepage =
| subpage = dontcat
| subsubpage = dontcat
}}
| only = {{#switch: {{#if:Help:Example | {{#if:{{#titleparts:Help:Example|0|3}} | subsubpage | {{#if:{{#titleparts:Help:Example|0|2}} | subpage | basepage }} }} | {{#if:{{#titleparts:Template:Category handler/testcases|0|3}} | subsubpage | {{#if:{{#titleparts:Template:Category handler/testcases|0|2}} | subpage | basepage }} }} }}
| basepage = dontcat
| subpage = | subsubpage = }}
}}
| |
{{#switch: {{#ifeq: | false | | {{#ifeq: | yes | | {{#ifeq: | yes | | {{#if:x
|
{{#if:{{#titleparts:{{#if:Help:Example| Help:Example | Template:Category handler/testcases }}|0|2}} | | }}
}}
}} }} }} | hide = | #default = {{#ifeq: h0#384!5nea+w9 | | {{#invoke:Namespace detect|main}} | {{#iferror: {{#expr: 1 + {{#invoke:Namespace detect|main}} }}
| {{#invoke:Namespace detect|main}} | }}
}} }}
}}x
x{{#if:
{{#ifeq: | true | dontcat }}{{#ifeq: | no | dontcat }}{{#switch: ¬ | yes | ¬ = | #default = dontcat }}{{#switch: | no = {{#switch: {{#if:Help:Example | {{#if:{{#titleparts:Help:Example|0|3}} | subsubpage | {{#if:{{#titleparts:Help:Example|0|2}} | subpage | basepage }} }} | {{#if:{{#titleparts:Template:Category handler/testcases|0|3}} | subsubpage | {{#if:{{#titleparts:Template:Category handler/testcases|0|2}} | subpage | basepage }} }} }}
| basepage =
| subpage = dontcat
| subsubpage = dontcat
}}
| only = {{#switch: {{#if:Help:Example | {{#if:{{#titleparts:Help:Example|0|3}} | subsubpage | {{#if:{{#titleparts:Help:Example|0|2}} | subpage | basepage }} }} | {{#if:{{#titleparts:Template:Category handler/testcases|0|3}} | subsubpage | {{#if:{{#titleparts:Template:Category handler/testcases|0|2}} | subpage | basepage }} }} }}
| basepage = dontcat
| subpage = | subsubpage = }}
}}
| |
{{#switch: {{#ifeq: | false | | {{#ifeq: | yes | | {{#ifeq: | yes | | {{#if:x
|
{{#if:{{#titleparts:{{#if:Help:Example| Help:Example | Template:Category handler/testcases }}|0|2}} | | }}
}}
}} }} }} | hide = | #default = {{#ifeq: h0#384!5nea+w9 | | {{#invoke:Namespace detect|main}} | {{#iferror: {{#expr: 1 + {{#invoke:Namespace detect|main}} }}
| {{#invoke:Namespace detect|main}} | }}
}} }}
}}x
x{{#invoke:Category handler|main}}x
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
x{{#invoke:Category handler|main}}x
x{{#invoke:Category handler|main}}x
x{{#invoke:Category handler|main}}x
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
x{{#invoke:Category handler|main}}x
x{{#invoke:Category handler|main}}x
x{{#invoke:Category handler|main}}x
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
x{{#invoke:Category handler|main}}x
x{{#invoke:Category handler|main}}x
x{{#invoke:Category handler|main}}x
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
x{{#invoke:Category handler|main}}x
x{{#invoke:Category handler|main}}x
x{{#invoke:Category handler|main}}x
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
x{{#if:
{{#ifeq: | true | dontcat }}{{#ifeq: | no | dontcat }}{{#switch: ¬ | yes | ¬ = | #default = dontcat }}{{#switch: no | no = {{#switch: {{#if:User:Example | {{#if:{{#titleparts:User:Example|0|3}} | subsubpage | {{#if:{{#titleparts:User:Example|0|2}} | subpage | basepage }} }} | {{#if:{{#titleparts:Template:Category handler/testcases|0|3}} | subsubpage | {{#if:{{#titleparts:Template:Category handler/testcases|0|2}} | subpage | basepage }} }} }}
| basepage =
| subpage = dontcat
| subsubpage = dontcat
}}
| only = {{#switch: {{#if:User:Example | {{#if:{{#titleparts:User:Example|0|3}} | subsubpage | {{#if:{{#titleparts:User:Example|0|2}} | subpage | basepage }} }} | {{#if:{{#titleparts:Template:Category handler/testcases|0|3}} | subsubpage | {{#if:{{#titleparts:Template:Category handler/testcases|0|2}} | subpage | basepage }} }} }}
| basepage = dontcat
| subpage = | subsubpage = }}
}}
| |
{{#switch: {{#ifeq: | false | | {{#ifeq: | yes | | {{#ifeq: | yes | | {{#if:x
|
{{#if:{{#titleparts:{{#if:User:Example| User:Example | Template:Category handler/testcases }}|0|2}} | | }}
}}
}} }} }} | hide = | #default = {{#ifeq: h0#384!5nea+w9 | Category:Somecat1 | {{#invoke:Namespace detect|main}} | {{#iferror: {{#expr: 1 + {{#invoke:Namespace detect|main}} }}
| {{#invoke:Namespace detect|main}} | }}
}} }}
}}x
x{{#if:
{{#ifeq: | true | dontcat }}{{#ifeq: | no | dontcat }}{{#switch: ¬ | yes | ¬ = | #default = dontcat }}{{#switch: no | no = {{#switch: {{#if:User:Example/test | {{#if:{{#titleparts:User:Example/test|0|3}} | subsubpage | {{#if:{{#titleparts:User:Example/test|0|2}} | subpage | basepage }} }} | {{#if:{{#titleparts:Template:Category handler/testcases|0|3}} | subsubpage | {{#if:{{#titleparts:Template:Category handler/testcases|0|2}} | subpage | basepage }} }} }}
| basepage =
| subpage = dontcat
| subsubpage = dontcat
}}
| only = {{#switch: {{#if:User:Example/test | {{#if:{{#titleparts:User:Example/test|0|3}} | subsubpage | {{#if:{{#titleparts:User:Example/test|0|2}} | subpage | basepage }} }} | {{#if:{{#titleparts:Template:Category handler/testcases|0|3}} | subsubpage | {{#if:{{#titleparts:Template:Category handler/testcases|0|2}} | subpage | basepage }} }} }}
| basepage = dontcat
| subpage = | subsubpage = }}
}}
| |
{{#switch: {{#ifeq: | false | | {{#ifeq: | yes | | {{#ifeq: | yes | | {{#if:x
|
{{#if:{{#titleparts:{{#if:User:Example/test| User:Example/test | Template:Category handler/testcases }}|0|2}} | | }}
}}
}} }} }} | hide = | #default = {{#ifeq: h0#384!5nea+w9 | Category:Somecat1 | {{#invoke:Namespace detect|main}} | {{#iferror: {{#expr: 1 + {{#invoke:Namespace detect|main}} }}
| {{#invoke:Namespace detect|main}} | }}
}} }}
}}x
x{{#if:
{{#ifeq: | true | dontcat }}{{#ifeq: | no | dontcat }}{{#switch: ¬ | yes | ¬ = | #default = dontcat }}{{#switch: only | no = {{#switch: {{#if:User:Example/test | {{#if:{{#titleparts:User:Example/test|0|3}} | subsubpage | {{#if:{{#titleparts:User:Example/test|0|2}} | subpage | basepage }} }} | {{#if:{{#titleparts:Template:Category handler/testcases|0|3}} | subsubpage | {{#if:{{#titleparts:Template:Category handler/testcases|0|2}} | subpage | basepage }} }} }}
| basepage =
| subpage = dontcat
| subsubpage = dontcat
}}
| only = {{#switch: {{#if:User:Example/test | {{#if:{{#titleparts:User:Example/test|0|3}} | subsubpage | {{#if:{{#titleparts:User:Example/test|0|2}} | subpage | basepage }} }} | {{#if:{{#titleparts:Template:Category handler/testcases|0|3}} | subsubpage | {{#if:{{#titleparts:Template:Category handler/testcases|0|2}} | subpage | basepage }} }} }}
| basepage = dontcat
| subpage = | subsubpage = }}
}}
| |
{{#switch: {{#ifeq: | false | | {{#ifeq: | yes | | {{#ifeq: | yes | | {{#if:x
|
{{#if:{{#titleparts:{{#if:User:Example/test| User:Example/test | Template:Category handler/testcases }}|0|2}} | | }}
}}
}} }} }} | hide = | #default = {{#ifeq: h0#384!5nea+w9 | Category:Somecat1 | {{#invoke:Namespace detect|main}} | {{#iferror: {{#expr: 1 + {{#invoke:Namespace detect|main}} }}
| {{#invoke:Namespace detect|main}} | }}
}} }}
}}x