Template:Main other: Difference between revisions

From All Skies Encyclopaedia
imported>Davidgothberg
(Yes it is over-engineered, but it is compatible with the other namespace detection templates.)
 
m (1 revision imported)
 
(7 intermediate revisions by 4 users not shown)
Line 1: Line 1:
{{#switch:
{{safesubst:<noinclude/>#switch:
<!--If no or empty "demospace" parameter then detect namespace-->
<noinclude><!-- If no or empty "demospace" parameter then detect namespace --></noinclude>
{{#if:{{{demospace|}}}
{{safesubst:<noinclude/>#if:{{{demospace|}}}
| {{lc: {{{demospace}}} }} <!--Use lower case "demospace"-->
| {{safesubst:<noinclude/>lc: {{{demospace}}} }} <noinclude><!-- Use lower case "demospace" --></noinclude>
| {{#ifeq:{{NAMESPACE}}|{{ns:0}}
| {{safesubst:<noinclude/>#ifeq:{{safesubst:<noinclude/>NAMESPACE}}|{{safesubst:<noinclude/>ns:0}}
| main
| main
| other
| other
}}
}}
}}
}}
| main = {{{1|}}}
<!--If any parameter, then don't return the "main/other" strings-->
| main = {{#if:{{{1|}}}{{{2|}}} | {{{1|}}} | main }}
| other
| other
| #default = {{#if:{{{1|}}}{{{2|}}} | {{{2|}}} | other }}
| #default = {{{2|}}}
}}<noinclude>


{{documentation}}
}}<!--End switch--><noinclude>
<!-- Add categories to the /doc subpage; interwikis go to Wikidata, thank you! -->

<!-- {{pp-template|small=yes}} -->
{{Documentation}}
<!-- Add categories and interwikis to the /doc subpage, not here! -->
</noinclude>
</noinclude>

Latest revision as of 13:57, 29 October 2025