Template:Talkspace detect/sandbox: Difference between revisions

Content deleted Content added
Adding the "anytalk" parameter.
No edit summary
 
(6 intermediate revisions by 4 users not shown)
Line 1:
{{safesubst:<noinclude/>#switch:
{{safesubst:<noinclude/>#if:{{{page|}}}
{{lc: <!--Lower-case the result-->
| {{safesubst:<noinclude/>#ifeq:{{safesubst:<noinclude/>NAMESPACE:{{{page}}} }}|{{safesubst:<noinclude/>SUBJECTSPACE:{{{page}}} }}
<!--If no or empty "demospace" parameter then detect namespace-->
| anysubject
{{#if:{{{demospace|}}}
| {{safesubst:<noinclude/>TALKSPACE:{demospace{{page}}} }}
}}
| {{#ifeq:{{NAMESPACE}}|{{SUBJECTSPACE}}
| {{safesubst:<noinclude/>#ifeq:{{safesubst:<noinclude/>NAMESPACE}}|{{safesubst:<noinclude/>SUBJECTSPACE}}
| subject
| {{TALKSPACE}}anysubject
| {{safesubst:<noinclude/>TALKSPACE}}
}}
}}
}}
<noinclude><!-- Only one of the lines below will be executed -->.
<!-- Respecting empty parameters on purpose. --></noinclude>
| anysubject = {{{other|}}} <noinclude><!--Any subject space--></noinclude>
| talkTalk = {{{talkmain| {{{anytalkdefault| {{{other|}}} }}} }}}
| userUser talk = {{{user talk| {{{anytalkdefault| {{{other|}}} }}} }}}
| wikipediaWikipedia talk = {{{wikipedia talk| {{{anytalkdefault| {{{other|}}} }}} }}}
| fileFile talk = {{{file talk| {{{anytalkimage| {{{otherdefault|}}} }}} }}}
| mediawikiMediaWiki talk = {{{mediawiki talk| {{{anytalkdefault| {{{other|}}} }}} }}}
| templateTemplate talk = {{{template talk| {{{anytalkdefault| {{{other|}}} }}} }}}
| helpHelp talk = {{{help talk| {{{anytalkdefault| {{{other|}}} }}} }}}
| categoryCategory talk = {{{category talk| {{{anytalkdefault| {{{other|}}} }}} }}}
| portalPortal talk = {{{portal talk| {{{anytalkdefault| {{{other|}}} }}} }}}
| subjectDraft talk = {{{subjectdraft| {{{otherdefault|}}} }}}
| MOS talk = {{{mos| {{{default|}}} }}}
| TimedText talk = {{{timedtext| {{{default|}}} }}}
| Module talk = {{{module| {{{default|}}} }}}
| Event talk = {{{event| {{{default|}}} }}}
| #default = {{{default|}}} <noinclude><!--A new talk space--></noinclude>
}}<!--End switch--><noinclude>
 
{{documentation}} -->
<!-- Only one of the lines below will be executed -->
<!-- Add categories and interwikis to the /doc subpage, notinterwikis go to Wikidata, thank hereyou! -->
<!-- Respecting empty parameters on purpose -->
 
| main <!-- demospace = main ... portal -->
| user
| wikipedia
| file
| mediawiki
| template
| help
| category
| portal
| subject = {{{subject| {{{other|}}} }}}
 
| anytalk = {{{anytalk| {{{other|}}} }}} <!-- demospace=anytalk -->
 
| talk = {{{talk| {{{anytalk| {{{other|}}} }}} }}}
| user talk = {{{user talk| {{{anytalk| {{{other|}}} }}} }}}
| wikipedia talk = {{{wikipedia talk| {{{anytalk| {{{other|}}} }}} }}}
| file talk = {{{file talk| {{{anytalk| {{{other|}}} }}} }}}
| mediawiki talk = {{{mediawiki talk| {{{anytalk| {{{other|}}} }}} }}}
| template talk = {{{template talk| {{{anytalk| {{{other|}}} }}} }}}
| help talk = {{{help talk| {{{anytalk| {{{other|}}} }}} }}}
| category talk = {{{category talk| {{{anytalk| {{{other|}}} }}} }}}
| portal talk = {{{portal talk| {{{anytalk| {{{other|}}} }}} }}}
 
| other
| #default = {{{other|}}} <!--"demospace=other" or a new talkspace-->
 
}}<!--End switch--><noinclude>
 
 
{{template sandbox notice}}
<!-- {{pp-template}}
{{documentation}} -->
<!-- Add categories and interwikis to the /doc subpage, not here! -->
</noinclude>