Do you just want to produce a link to the template?  Then use:

[[Template:NameOfTemplate]]

The <noinclude> tag does not prevent templates inside it from evaluating.  It 
marks a region of the article that should not be transcluded into OTHER 
articles.

A quick example. You have a template T and article A.  In template T, you write:

Hello <noinclude>world</noinclude>

When you render Template:T by itself, you see "Hello world"

In article A you write:

{{T}}

When article A is rendered, you see only "Hello". Because you told template T 
not to permit "world" to be transcluded into other articles.

DanB

-----Original Message-----
From: [email protected] 
[mailto:[email protected]] On Behalf Of Mary Ann Davison
Sent: Thursday, October 29, 2009 2:26 PM
To: [email protected]
Subject: [Mediawiki-l] noinclude doesn't work

According to the documentation, I should be able to reference a template
by doing this:

 

<noinclude>

{{NameOfTemplate}}

</noinclude>

 

But Mediawiki is transcluding the template into the page and I don't
want it there.  I just want developers to be able to click the template
and grab the template text when they're creating a new article.

 

Is there a setting in LocalSettings.php that I need to make to get
<noinclude> to work?  Someone else here installed the software, so I
haven't worked with that file, yet.

 

Anyone else have this problem?

 

Thanks,

Maffy

_______________________________________________
MediaWiki-l mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-l

_______________________________________________
MediaWiki-l mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-l

Reply via email to