function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
gyorkozgyorkoz 

inputTextarea line breaks and spaces

I am using an inputTextarea for a custom outgoing email but my vf page cannot maintain line breaks or spaces. It seperates every word with one char long space regardless of how you indented your text.

 

e.g: I type:

'

 a     b

     c

 d    

    e    f  '

 

I'll get:

'a b c d e f'

 

thanks

 

Best Answer chosen by Admin (Salesforce Developers) 
ColinKenworthy2ColinKenworthy2

That is standard browser behaviour. They ignore repeated spaces / line breaks and just show one space. You may need to use the pre-formatted text <pre> tag in your page.