![]() | |
![]() |
| | Thread Tools | Display Modes |
#1
| |||
| |||
|
#2
| |||
| |||
|
|
Hi... I have a problem where a nested <div> isn't changing the height of its parent div. I have a parent div which contains a child div and some text. The child div is a box to hold a list of thumbnail images. If the thumbnail div has several images in it, it overflows the parent div. How can I make this div affect the height of the parent div? |
|
div.thumbnails { float : right; } |
#3
| |||
| |||
|
|
I have a problem where a nested <div> isn't changing the height of its parent div. div.thumbnails { float : right; } |
#4
| |||
| |||
|
#5
| |||
| |||
|
#6
| |||
| |||
|
|
Charles Blaquière wrote: However, I'd like the cleared element to be as small as possible. (See border on element, for debugging purposes) I've tried: clear: both; height: 0; line-height: 0; font-size: 0; and it *still* has a height! (At least in IE6. Hint: the height varies according to the browser's default font size.) What are you using to get a cleared div as close to invisible as can be? visability: none? |
#7
| |||
| |||
|
|
Charles Blaquière wrote: However, I'd like the cleared element to be as small as possible. (See border on element, for debugging purposes) I've tried: clear: both; height: 0; line-height: 0; font-size: 0; and it still has a height! (At least in IE6. Hint: the height varies according to the browser's default font size.) What are you using to get a cleared div as close to invisible as can be? visability: none? |
#8
| |||
| |||
|
|
Charles Blaquière wrote: No, if I set "display: none", the cleared div is removed from the flow and the main div shrinks back down to a height smaller than the floated div. not display: none. visability, which creates a box in the flow, but makes that box invisible. |
#9
| |||
| |||
|
#10
| |||
| |||
|
![]() |
| Thread Tools | |
| Display Modes | |
| |