partlycloudy
partlycloudy

Reputation: 429

Overflow in DIV by wrapping not scrollbars

Given a DIV with a fixed width, is there a way to have it use as much vertical space as it needs by wrapping the content (which is plain text)? The CSS "overflow" property provides for scrollbars (overflow:scroll) and chopping content (overflow:hidden) but that's not what I want.

Help? Thanks

Upvotes: 1

Views: 293

Answers (1)

Robusto
Robusto

Reputation: 31883

Yeah. Just leave it alone. It will resize to the content vertically just fine. Your page might get a scrollbar, though.

Upvotes: 2

Related Questions