Today I had to do some searching to find a solution for an internationalization problem. I had a div with a fixed width of 140px and wanted to ensure the text fit inside this div and automatically wrapped. In order to do that I had to find the right css. At first I thought using white-space: pre-wrap would work. However, the problem with that is it only wraps between spaces. So:
this is a
long area
with a
forced
wrap
would look okay. But the following would not wrap and would overflow into the other divs:
thisisalongareawithaforcedwrap
In order to fix that (I was doing it for internationalization purposes) I used this:
word-wrap: break-word;Worked like a charm!!
MSTC Graduation
-
[image: IMG_1284]
IMG_1284,
originally uploaded by MSTCprogram.
Yay! I graduated this weekend from the University of Texas with an MS in
Technology Commerci...
14 years ago