Jump to content

Template:Box: Difference between revisions

From Ash's Lecture Notes
Ash (talk | contribs)
Document equals signs in template content
Ash (talk | contribs)
Accept named body argument for equations
Line 1: Line 1:
<includeonly><div class="physics-box"><div class="physics-box-body">
<includeonly><div class="physics-box"><div class="physics-box-body">
{{{body|{{{1|}}}}}}
</div></div></includeonly><noinclude>Use <code><nowiki>{{Box|Your content}}</nowiki></code> for simple text. Use <code><nowiki>{{Box|body=$E=mc^2$}}</nowiki></code> when content contains equals signs; the snippet inserts this named form automatically.</noinclude><includeonly><div class="physics-box"><div class="physics-box-body">
{{{1|}}}
{{{1|}}}
</div></div></includeonly><noinclude>Use <code><nowiki>{{Box|Your content}}</nowiki></code> for a simple bordered box. If the content contains an equals sign, use <code><nowiki>{{Box|1=$E=mc^2$}}</nowiki></code>, as MediaWiki otherwise treats it as a named parameter.</noinclude>
</div></div></includeonly><noinclude>Use <code><nowiki>{{Box|Your content}}</nowiki></code> for a simple bordered box. If the content contains an equals sign, use <code><nowiki>{{Box|1=$E=mc^2$}}</nowiki></code>, as MediaWiki otherwise treats it as a named parameter.</noinclude>

Revision as of 09:15, 29 September 2026

Use {{Box|Your content}} for simple text. Use {{Box|body=$E=mc^2$}} when content contains equals signs; the snippet inserts this named form automatically.Use {{Box|Your content}} for a simple bordered box. If the content contains an equals sign, use {{Box|1=$E=mc^2$}}, as MediaWiki otherwise treats it as a named parameter.