Difference between revisions of "User:Timbeale"

 
(3 intermediate revisions by the same user not shown)
Line 1: Line 1:
Sandpit page to demonstrate mediawiki transclusion.
+
Sandpit page to demonstrate mediawiki transclusion. For more details, see https://www.mediawiki.org/w/index.php?title=Transclusion
  
 
= Transclude whole page =
 
= Transclude whole page =
Line 7: Line 7:
 
Note the ':' is important, otherwise it defaults to using the ''Template'' namespace. You could alternatively make it explicit that the page you want to transclude is in the ''Main'' namespace, i.e. <nowiki>{{Main:License}}</nowiki> does the same thing.
 
Note the ':' is important, otherwise it defaults to using the ''Template'' namespace. You could alternatively make it explicit that the page you want to transclude is in the ''Main'' namespace, i.e. <nowiki>{{Main:License}}</nowiki> does the same thing.
  
== Example ==
+
== Transcluded content ==
  
 
{{:License}}
 
{{:License}}
Line 15: Line 15:
 
The below example uses the same transclusion (of a different page - <nowiki>{{User:Timbeale/transclusion}}</nowiki>) to include just part of the [[User:Timbeale/transclusion]] page.  
 
The below example uses the same transclusion (of a different page - <nowiki>{{User:Timbeale/transclusion}}</nowiki>) to include just part of the [[User:Timbeale/transclusion]] page.  
  
== Example ==
+
== Transcluded content ==
  
 
{{User:Timbeale/transclusion}}
 
{{User:Timbeale/transclusion}}
 +
 +
== My WIP ==
 +
[[User/Timbeale/Replace cwrap with namespaces]]

Latest revision as of 20:45, 7 February 2019

Sandpit page to demonstrate mediawiki transclusion. For more details, see https://www.mediawiki.org/w/index.php?title=Transclusion

Transclude whole page

The below example uses {{:License}} to include the entire License page.

Note the ':' is important, otherwise it defaults to using the Template namespace. You could alternatively make it explicit that the page you want to transclude is in the Main namespace, i.e. {{Main:License}} does the same thing.

Transcluded content

Content is available under the Creative Commons License CC BY 4.0

https://creativecommons.org/licenses/by/4.0/

Transclude part of page

The below example uses the same transclusion (of a different page - {{User:Timbeale/transclusion}}) to include just part of the User:Timbeale/transclusion page.

Transcluded content

Here! This paragraph is wrapped in <onlyinclude> markers. It is both visible on the original page it appears on, and any other page that transcludes the original.

My WIP

User/Timbeale/Replace cwrap with namespaces