comn8u
08-20-2007, 12:52 PM
How do you expand outer divs when content fills divs that reside inside the outer divs?
Also, how do you make a set height on a div that would allow it to expand when content fills it?
Normally, when you have nested divs, the outermost div will expand as the inner div does also. However, if you have floated the inner div, the outer div will retain its original dimensions (not expanding) because the floated div is considered "out of the box" of the outermost div.
As to a set height, you can use either min-height, or set a height with overflow: visible. However, IE doesn't recognize min-height, and overflowing divs can be tricky if you're using backgrounds; sometimes the backgrounds will not expand with the textual contents.
KDLA