pre {
font-family: sans-serif, helvetica, arial;
white-space: pre-wrap; /* css-3 */
white-space: -moz-pre-wrap; /* Mozilla, since 1999 */
white-space: -pre-wrap; /* Opera 4-6 */
white-space: -o-pre-wrap; /* Opera 7 */
word-wrap: break-word; /* Internet Explorer 5.5+ */
}
<pre style="font-family: sans-serif, helvetica, arial; white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">
I find this useful for wikis and other random one-off posting of text on the internet.
Adapted from http://users.tkk.fi/tkarvine/pre-wrap-css3-mozilla-opera-ie.html
anyall.org