Template talk:Warning message
From Meta, a Wikimedia project coordination wiki
Editprotected request [edit]
{{editprotected}} Please use the new #safesubst:, as so:
{| class="messagebox plainlinks user-block" style="margin-left:0; padding:5px; background:#F9F9F9; {{{CSS-box|}}}"
| {{<includeonly>#safesubst:</includeonly>#ifeq:{{{image}}}|none||[[{{{image|File:Stop x nuvola.svg}}}|50px]]}}
| {{{msg}}}
|}
The ParserFunction will be substed when this template is substed, and will remain the same when this template is transcluded. —MC10 (T•C•EM) 04:30, 9 November 2010 (UTC)
- Tried it, and that seems to have broken the template (substituting produced an extraneous "none}}" and transclusion simply pasted the template code with "subst:"). Could you test the code in a sandbox first? Jafeluv 10:03, 9 November 2010 (UTC)
-
- Now it should work. I have created Template:Warning message/sandbox and Template:Warning message/testcases. I put an extra # in front of safesubst; it should just be safesubst:, not #safesubst:. The following code should work:
{| class="messagebox plainlinks user-block" style="margin-left:0; padding:5px; background:#F9F9F9; {{{CSS-box|}}}"
| {{<includeonly>safesubst:</includeonly>#ifeq:{{{image}}}|none||[[{{{image|File:Stop x nuvola.svg}}}|50px]]}}
| {{{msg}}}
|}