Quantcast
Channel: nixer.org
Viewing all articles
Browse latest Browse all 10

Using CSS to prevent arbitrary line breaks at slashes (/)

$
0
0

In working with HTML, many of you have probably dealt with the issue of unsightly line breaks being inserted by the browser from word wrapping. Automatic word wrapping is usually quite predictable, happening when the browser meets whitespace or a hyphen. You can use special characters to control whether the wrap happens or not, e.g. a non-breaking space ( ) or a non-breaking hyphen (&#8209). But did you know that word wrap also happens at slash (/) characters?

For example, take a look at the following line:

read more


Viewing all articles
Browse latest Browse all 10

Trending Articles