View Full Version : Expand a nested div

Feb 29th, 2008, 03:34 PM

I have a div that should be able to expand depending on how much data is in it.
The problem is thats it is contained with a few other divs.
The data simply writes to the nested div and flows downwards out of the div, over my footer and on for ages.
I there a property i can set to fix this?


Feb 29th, 2008, 03:51 PM
most likely! Do you have code you can post or maybe a link that we could look at?

Feb 29th, 2008, 04:07 PM

Note that it dosent show up at the moment because i put a temporariry height of 3420px on the div inside divs (outerWrapper->contentWrapper->content->containerSiteMap).

This site map is dynamically created and it would be much better to have the div expand to fix instead of changing its height every time new site content is added.

Feb 29th, 2008, 04:21 PM
this is currently what your conatinerSiteMap says,

#containerSitemap {
width: 770px;
text-align: left;
position: relative;
top: 0;


and its not set too 3420px, which div is set to that amount? I cant find it!

Feb 29th, 2008, 04:33 PM
if you remove the height attributs off all the divs in your dynamic site map they will just expand as things are added!

maybe set a min-height or some thing!?

Feb 29th, 2008, 04:47 PM
If you expand conmtainsSitemap iin firebug you will see a seperate div about 10 lines line with no id attached to it, it has the height.

Feb 29th, 2008, 04:51 PM
ok i see what you mean the footer screws up as well when the height is removed , 1 sec im goona have a clser look

Edit. cant doit im getting lost in all the divs sorry ! but if you can remove the heights on the site map container and add a min height to you pag container may help in some way !