Forum:Templates: Transcluding a redirect

On the Programmer's Wiki, we have a glossary, sections of which several pages redirect to. I was hoping to make these redirects more manageable by abstracting them into a temp[ate which would be transcluded onto them. Unfortunately, as the template code contains a redirect, the glossary itself is transcluded rather than a redirect, and the section within it is not scrolled to. I tried using the ASCII codepoint &amp;#35; in place of the &#35;, but this prevents MediaWiki from honoring the redirect at all. Is there any way to make this work?

Thanks! --Jesdisciple (talk) 05:48, June 24, 2010 (UTC)


 * I think it would be easier to make each glossary entry a separate page (maybe a subpage) and transclude them all together in the glossary and then individually wherever you want them to appear. The trick is to make sure each entry has an edit link somewhere unobtrusive, so people can still easily update the entries. You don't need to put pages in the Template: namespace to transclude them. For non-Template: namespace pages, use  to transclude them. Make sure to use   around portions of pages you want to transclude. --  Fandyllic  (talk &middot; contr) 8:37 AM PST 24 Jun 2010


 * I have been considering that, but I do like having each term nested within all the others no matter how the reader arrives at it. The problem (and I don't think transcluded entries fix this) is that if we decide to change an entry's title then we have to track down OOP, Object-Oriented_Programming, Object-oriented_programming, and any other page titles we thought fit.  A template would be able to mark each page with  (with a bot creating those category pages).  Or Semantic MediaWiki might have a sleeker solution... I haven't looked into that yet.  (Sorry folks, my siggy broke for some reason...  I'm Jesdisciple. =P) --Jesdisciple (talk) 15:02, 25 June 2010 (UTC)
 * Close ur taggs!  Manyman  (Talk)  12:39, June 25, 2010 (UTC)
 * I haven't tested this but try putting just the destination section in the template, so on the individual term page you would have e.g., #REDIRECT Glossary
 * Again, don't know if it will work, if not there is a way to make this work without redirects. You would need a template (called Template:GlossaryEntry in this example) which would look like:


 * Then on the glossary page you would need to do something like:

==Section 1==

Section 2

 * Then on the calling page you would put:


 * or


 * Depending on which term you were wanting. Hope this helps.-- 14:17, June 25, 2010 (UTC)


 * Cool, I didn't know LabeledSectionTransclusion was one of the standard extensions now. Jesdisciple, check Special:Version and if it lists LabeledSectionTransclusion, Pcj's stuff should work. -- Fandyllic  (talk &middot; contr) 11:22 AM PST 25 Jun 2010
 * Pretty much the same method either way, though mine doesn't use that extension. -- 18:24, June 25, 2010 (UTC)


 * Woops, sorry I forgot to respond. Pcj's first solution doesn't work, so I'll have to get to work converting the glossary for the second.  LabeledSectionTransclusion isn't on my wiki, but if I hadn't recently requested an extension that's not in w:c:help:Category:Extensions enabled on request I would ask that it be added.  Apparently Wikia has to import each extension into SVN, so I don't feel comfortable asking for another extra one. --Jesdisciple (talk) 12:50, June 29, 2010 (UTC)