Back

Explore Courses Blog Tutorials Interview Questions
0 votes
2 views
in Web Technology by (20.3k points)

How do you use the CSS content property to add HTML entities?

Using something like this just prints   to the screen instead of the non-breaking space:

.breadcrumbs a:before {

    content: ' ';

}

1 Answer

0 votes
by (40.7k points)

You need to use the escaped Unicode like this:

.breadcrumbs a:before {

    content: '\0000a0';

}

For more information you can refer to:

 http://www.evotech.net/blog/2007/04/named-html-entities-in-numeric-order/

Related questions

Browse Categories

...