Friday, April 15, 2011

Forcing Line-Breaks in a Cross-Browser Manner

This works in IE versions 6-9 as well as Firefox and Chrome:

word-wrap:break-word;

word-break:break-all;



This will force linebreaks in strings of really-really-really-really long text so that they do not overflow their container (ie: a DIV).

No comments:

Post a Comment