Badge time.png   The Paragon Wiki Archive documents the state of City of Heroes/Villains as it existed on December 1, 2012.

User talk:Zombie Man

From Paragon Wiki Archive
Revision as of 14:30, 18 April 2010 by Zombie Man (Talk | contribs) (Template:Bug)

(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search

Templates and the noinclude tag

I noticed you went through and fixed the categorization of the templates -- awesome job! It's been long overdue for getting done. However, there's a subtle mistake you introduced on a lot of pages that I wanted to make you aware of for future reference. When adding a noinclude section to the end of a page, you have to make sure you don't add any whitespace before the opening tag. For example, if a template consists of this:

|}

And you change it to this:

|}
<noinclude>[[Category:Example]]</noinclude>

You've just added whitespace to the template. On some templates, this can seriously break the functionality -- for example, if the template is meant to be used in-line, having linebreaks can really throw things off and break formatting in unexpected ways. The correct way to do it is this:

|}<noinclude>
[[Category:Example]]</noinclude>

The important thing is that the opening <noinclude> gets glued right up against the last character that is going to get transcluded into the article.

It's a very common and subtle error, just wanted to make you aware of it in case you have any further categorizing to do. -- Sekoia 01:29, 22 February 2010 (UTC)


Sorry about that. I started to realize that near the end of the categorization process while working on the Template Help file (which makes that specific point twice over so that other newbs don't make the same mistake.

Template:Bug

Your edit comment was "Changed coding to remove deprecated 'messagebox' but mostly to create a template that allows a hyperlink as an argument.". I'm not entirely clear what you were working towards, but I'm wondering if you were running into problems with a hyperlink that contains an equal sign? If so, then the solution is to call the template like this: {{bug|1=Here is my link: http://example.com?foo=bar}} In other words, you have to explicitly use the option name (which is "1" for this template) rather than using positional arguments. Otherwise, it uses everything before the equal sign in the link as a parameter name, and since there is no parameter named "Here is my link: http://example.com?foo" the net effect is that it all just gets ignored.

If that wasn't the problem you were bumping into, then just ignore me. :) -- Sekoia 01:35, 18 April 2010 (UTC)

Thank-you! I thought I was going crazy. Since the Bug Template wasn't accepting the link, I thought it was a problem with Tables (that used a deprecated Messagebox style according to Big Wiki) in the Template, so I re-wrote it as a div box; and it still didn't work. The equal signs was the problem and your work-around worked. Thanks! Zombie Man 14:30, 18 April 2010 (UTC)