Scary tranclusion
Scary transclusion not working?
Pure transclusion
Raw transclusion
This is the solution for your problem. Use {{raw:templatewiki:Userlist}} to get the wanted result.}}
{{InfoBox|1=The drawback of this method is that all included templates must be defined locally. Therefore I recommond following approach:
- if you want to transclude template template sample define a template with the same name in the local wiki
- insert following text into your template: <includeonly><onlyinclude>{{raw:templatewiki:template sample}}</onlyinclude></includeonly>
- define all used subtemplates in the same way
Transclusion of a page outside the template namespace
Die Informationen auf der Dokumentationsseite, wie eine Seite zu transkludieren ist, die sich nicht im Vorlagennamensraum des remote Wiki befindet, sind mindestens verwirrend, wenn nicht gar falsch.
Die Syntax lautet: {{interwiki-prefix::{{FULLPAGENAME}}}}
Ein konkretes Beispiel: {{raw:templatewiki::User:Lily/sandbox}}
ergibt
This is a test.
Transclusion from main namespace: {{raw:yazz::Transclusion}} results in
linear-gradient(to right, red, #f80, #ff0, #8f0, #0f0, #0f8, #0ff, #08f, #00f, #80f, #f0f, #f08)Vorlagendokumentation
If the template in the remote wiki contains template documentation, you can include this documentaton with {{templatewiki:template sample}} The content of your template would look like this
<includeonly><onlyinclude>{{raw:templatewiki:template sample}}</onlyinclude></includeonly> {{templatewiki:template sample}}
If you want to make this even better define a template eg {{Transdoc}} in your local wiki that looks like this
<includeonly><onlyinclude>__NOTOC__{{#switch:{{NAMESPACENUMBER}}
|10=
{{anm
|1=Diese Dokumentation wird eingebunden von der Vorlage {{Tl|1=Transdoc}}}}
<!-- {{VListe|VLily|Transclution|Aus dem Lilypond Wiki eingebundene Vorlagen}} -->
== Local description ==
[[Special:WhatLinksHere/Template:{{PAGENAME}}|Lokale Verwendungen der Vorlage {{PAGENAME}}]]
=== Local code ===
<div style="background-color: #aaa; width: 90%; border-radius: 1em; box-shadow: 0.1em 0.1em 0.5em rgba(0,0,0,0.75); padding: 0.5em;"><div style="background-color: #fff; padding: 1em; border-radius: 0.5em; font-family: monospace; white-space: pre-wrap;">
{{msgnw:{{FULLPAGENAME}}}}</div></div>
=== Local Subpages ===
{{:Special:PrefixIndex/{{FULLPAGENAME}}/}}
== Remote Description ==
<div>{{anm
|1=Diese Vorlage sowie die [[#Remote Description|dazugehörige Dokumentation]] wird aus dem [[{{{pre|lily}}}:{{FULLPAGENAME}}|{{{wiki|Lilypond Wiki}}}]] eingebunden.<br>
Sämtliche Links verweisen auf das [[{{{pre|lily}}}:|{{{wiki|Lilypond-Wiki}}}]]}}</div>
{{{{{pre|lily}}}:{{{vorlage|{{PAGENAME}}}}}}}
}}{{Cats|Transcluded from {{{wiki|Lilypond Wiki}}}}}<!-- end of switch --></onlyinclude></includeonly>