mediawiki

How can I force MediaWiki to respect single line breaks?


By default, MediaWiki ignores single line breaks, treating them as a single space. To insert a new line in a page, you must insert two consecutive line breaks in the source, which results in a new paragraph: </p><p>. It's also possible to insert <br /> directly into the source.

How can I get MediaWiki (control its parsing engine) to convert single line breaks in the source to <br /> elements in the resulting HTML?

(Source: http://www.mediawiki.org/wiki/Help:Formatting)


Solution

  • Use https://www.mediawiki.org/wiki/Extension:Poem

    <poem>
    Roses are red
    Violets are blue
    </poem>