Template talk:!

From Fanlore
Jump to navigation Jump to search

What is this? I assume it has some purpose, but the template page doesn't explain anything. It looks odd in the template list.--RatCreature 09:41, 20 May 2010 (UTC)

Yes, it does have a purpose. When using the ParserFunctions extension for table fields, using the regular | table markup creates a conflict—the extension works with the if something | something | something syntax, "|" indicating "then" and "else," respectively.

Therefore, if I want to write a line of wiki markup in a fanlore template that means: "if the page that includes this template has a 'fandom=' defined, create a row in the table with 'fandom' on one side and the fandom in question on the other," I will write this:

{{#if: {{{fandom|}}} |
! Fandom {{!}} {{!}} {{{fandom}}}
}}

If I were to write that in regular wiki markup, it would be "! Fandom || {{{fandom}}}", yeah? But if I use "|" it will think I mean "else," which will mess things up. Does that make sense to you? :D --ChristyCorr 16:07, 20 May 2010 (UTC)


Request Usage Note

I see there's an explanation up there, which I don't really understand but that's cool. But right now it's user-hostile, and a bad experience for new editors. I'd like to see an explanation added to the template info, as a usage note like the others. And if it could be forced to sort at the end, that would be even better. That way, the experts can use it and the newbies will almost never see it. --Msilfan (talk) 22:59, 28 January 2017 (UTC)

Yes, I think that's a good idea, but I'm not expert enough to write that note. So I put the 'Attention Gardeners' template here, hoping it attracts someone who can/is willing to write it. SecurityBreach (talk) 14:40, 3 April 2021 (UTC)
Yea that explanation made my head hurt. I looked for transclusions here. There aren't any. This template is linked from a talk page and the documentation of another template. So I looked into this users template edits, as from their explanation, its clear that this template is designed for use when writing code for other templates - but this is the last template they edited. As in they didn't go on to use this template when coding other templates. I don't think this template is currently in use on the Wiki, so I'm wondering if we need to keep it... --Auntags (talk) 20:46, 12 April 2021 (UTC)

Delete?

It looks like MediaWiki added this syntax as a magic word, making this template redundant (see also Wikipedia:Template:!). I think it can safely be deleted since it's causing confusion. We can update Help:Magic words if we want to give an explanation of how the code is used, but it's probably advanced enough that people can refer to MediaWiki if necessary. --sparc 01:50, 12 August 2021 (UTC)

Agree to deletion proposal. I just tested that magic word syntax and it seems to work in preview on a Fanlore page. -- Auntags (talk) 12:00, 24 August 2021 (UTC)