0
votes

I have a text area tinymce file that removes extra spaces and I don't want that.

For example if in the text area if I put hello, 5 spaces, bye, and when I save the file and view it again, 4 spaces are deleted and I see hello bye. (4 extra spaces are deleted)

Sorry if I sound not too informed about this, but I just wonder if this is a default feature or if there is an easy way to turn off this feature. (I do not want the extra spaces to be deleted.)

Thanks,

1

1 Answers

1
votes

The issue here is that modern browsers will not display several spaces - but will show them as one single space. The solution here is to replace every second space with a " " before the content gets into the editor (best is to replace them on serverside). This way the browser will show all the spaces.