EricLynnWright
asked on
DIV with scroll - how to make it have auto height?
I have a DIV that gets filled in with a report. It has the "overflow: auto;" to enable scrolling within.
I want to make the DIV still scrollable but I want it to adjust the DIV size to the screen size of the user as opposed to hard coding the "height" property within CSS.
The page is made up of sections - a header and then the DIV below that. So I was hoping to be able to have the DIV start at an absolute location and fill in to the bottom of the screen automatically.
CSS now for DIV:
#report_area
{
position: absolute;
top: 97px;
left: 0px;
height: 700px;
width: 100%;
overflow: auto;
}
I want to make the DIV still scrollable but I want it to adjust the DIV size to the screen size of the user as opposed to hard coding the "height" property within CSS.
The page is made up of sections - a header and then the DIV below that. So I was hoping to be able to have the DIV start at an absolute location and fill in to the bottom of the screen automatically.
CSS now for DIV:
#report_area
{
position: absolute;
top: 97px;
left: 0px;
height: 700px;
width: 100%;
overflow: auto;
}
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.