Difference between revisions of "Template:Blockquote paragraphs"
From D&D 5e
(tweak) |
(loops again) |
||
Line 1: | Line 1: | ||
Due to the utterly intractable [[MediaWiki]] bug reported at {{bugzilla|6200}}, block quoting cannot handle freeform linebreaking for paragraphs and poems and the like. The {{em|only}} solution for this is to use unbroken markup with {{tag|p}} or {{tag|br|single}} elements: | Due to the utterly intractable [[MediaWiki]] bug reported at {{bugzilla|6200}}, block quoting cannot handle freeform linebreaking for paragraphs and poems and the like. The {{em|only}} solution for this is to use unbroken markup with {{tag|p}} or {{tag|br|single}} elements: | ||
− | :{{tnull|{{BASEPAGENAME}}|Line 1<br/>Line 2<br/>Line 3<br/>Line 4.}} | + | :{{tnull|<includeonly>{{BASEPAGENAME}}</includeonly><noinclude>bq</noinclude>|Line 1<br/>Line 2<br/>Line 3<br/>Line 4.}} |
Which results in: | Which results in: | ||
− | :{{{{BASEPAGENAME}}|Line 1<br/>Line 2<br/>Line 3<br/>Line 4.}} | + | :{{<includeonly>{{BASEPAGENAME}}</includeonly><noinclude>bq</noinclude>|Line 1<br/>Line 2<br/>Line 3<br/>Line 4.}} |
However there is an HTML-comment workaround for readability that lets you do whatever you want, and is even indentable with <code>*, : and #</code> markup: | However there is an HTML-comment workaround for readability that lets you do whatever you want, and is even indentable with <code>*, : and #</code> markup: |
Revision as of 17:52, 2 February 2012
Due to the utterly intractable MediaWiki bug reported at Template:Bugzilla, block quoting cannot handle freeform linebreaking for paragraphs and poems and the like. The Template:Em solution for this is to use unbroken markup with {{#if:|
|
}}{{#switch:pair
|c|close = |s|single |o|open |p|pair = <p{{#if:| {{{params}}}}}
}}{{#switch:pair
|c|close = |s|single = /> |o|open = > |p|pair = >...
}}{{#switch:pair
|s|single |o|open = |c|close |p|pair = </p>
}}{{#if:|
|
}} or {{#if:|
|
}}{{#switch:single
|c|close = |s|single |o|open |p|pair = <br{{#if:| {{{params}}}}}
}}{{#switch:single
|c|close = |s|single = /> |o|open = > |p|pair = >...
}}{{#switch:single
|s|single |o|open = |c|close |p|pair = </br>
}}{{#if:|
|
}} elements:
Which results in:
However there is an HTML-comment workaround for readability that lets you do whatever you want, and is even indentable with *, : and #
markup:
{{bq|1=<!--
-->Line 1<br/><!--
-->Line 2<br/><!--
-->Line 3<br/><!--
-->Line 4.}}
Or even:
{{bq|1=<!--
-->Line 1<br/><!--
-->Line 2<br/><!--
-->Line 3<br/><!--
-->Line 4.}}
Result of either:
Editors can experiment in this template's sandbox (create | mirror) and testcases (create) pages. Please add categories to the /doc subpage. Subpages of this template. |