html - Classic 'inner div to fill rest of height'-question! -
i've tried find solution matches basic css problems when designed new pages. without luck, though has come close...
say have following:
- a main div wrapper fill 100% height (no problem)
- an inner div fill rest of height plus contents (scrollable) <-- hard imo.
the content
div should fill rest of height...
the problem if use position:absolute
,left:0;bottom:0;top:0;
on content
; if contents of content
exceeds browser's initial height, happen:
... , page weird-looking. would nice, if div itself, scale contents... :-)
how possible?
there no way in css (although maybe guru come , show me wrong), may helpful read sticky footers,
http://www.cssstickyfooter.com/
also discussed on several threads here, if trying ensure footer won't appear halfway down page. can accomplished purely css, , if absolutely need content div take remaining space (nothing body background shouldn't able take care of..), can use javascript set height of element document.height - height of header , footer.
i'm sorry wasn't able give better response, 3 minutes left on laptop battery, i'll back.
Comments
Post a Comment