Help talk:Newlines and spaces

Creating a new line...

edit

I am wondering if any of you guys can help me. I am attempting to use ParserFunctions to create a unit converter for my wiki. The issue is that the "#expr" code is creating a new line after every use. My code is below. Any help would be SOOOOO appreciated! Thanks!!! --Zackmann08 (talk) 22:22, 1 May 2012 (UTC)Reply

The template:

<includeonly>"{{#expr:({{{1}}}* 2.2046)round2}} lbs ({{{1}}} kg)"</includeonly>

The use of the template:

* '''Weight''': {{convert/kg|1}}
* '''Weight''': {{convert/kg|2}}

What it produces:

  • Weight: "2.2 lbs (1 kg)"

  • Weight: "4.41 lbs (2 kg)"


What I WANT it to produce:

  • Weight: "2.2 lbs (1 kg)"
  • Weight: "4.41 lbs (2 kg)"

Prevent non-breaking space replacement in <syntaxhighlight>

edit

Is there a way to prevent a space before a percent symbol from being replaced by a non-breaking space in a <syntaxhighlight> block? I want to be able to copy the code block and paste it into a config file, and non-breaking spaces are causing issues. Lomedhi (talk) 18:37, 18 November 2022 (UTC)Reply

Return to "Newlines and spaces" page.