CSS: how to add white space before element's content?

The Solution to CSS: how to add white space before element's content? is


You can use the unicode of a non breaking space :

p:before { content: "\00a0 "; }

See JSfiddle demo

[style improved by @Jason Sperske]

~ Answered on 2013-05-14 20:36:11


Most Viewed Questions: