Other Sites

VA Roper Art & Design

Writuar: Unleash your Writing Animal!

What I eat, apparently.

Salami Day

Spin the Globe!



September 2015

    1 2 3 4 5
6 7 8 9 10 11 12
13 14 15 16 17 18 19
20 21 22 23 24 25 26
27 28 29 30

rss feed


Valid CSS!


Log in

ptocheia [userpic]

How I finally figured out how to deal with stupid overflowing text

March 23rd, 2013 (09:46 pm)

So I have randomly come across this issue where I’ve got text that needs to fit into a specific area – not all the text needs to show, but enough of it so you know what’s going on there, content-wise. This seems to happen with table data, and of course I’ve got to deal with how the content moves around on smaller screens – and usually it’s a case of where everything needs to stay on one line. So I’ve done some half-assed php character limiting, where really there was a much more elegant solution sitting out there waiting for me this entire time.

white-space: nowrap;

overflow: hidden;

text-overflow: ellipsis;

I feel kinda dirty about the fact that I discovered this via Yahoo’s homepage, but I’ll take what I can get.

Reply   Link


Peru 2007

Florida 2006

Camping in Western VA & WV 2006

Florida 2005


How sexy are you?

What pisses you off?

What kind of goth are you?

What's your sexual perversion?

Discover what your fortune holds for you!