The word-wrap
property wraps long words to the next line.
word-wrap: normal|break-word|initial|inherit;
word-wrap |
Yes | Yes | Yes | Yes | Yes |
<!DOCTYPE html>
<html>
<head>
<style>
p.test {<!-- w w w . j a v a2 s .c om-->
width: 11em;
border: 1px solid #000000;
word-wrap: break-word;
}
</style>
</head>
<body>
<p class="test"> this is a test: thisisaveryveryveryveryveryverylongword.
</p>
</body>
</html>