Fixed header section with scrollable bottom

I am working on a layout where my client would like the header section to be fixed and the page content to be at 100% of the available height and scroll when overflowing (so the page itself never scrolls). enter image description here

The problem I'm working with is that the content of the header section is different on every page and should have a flexible height in cases where the content of the header created by the user becomes very long and requires wrapping, t really sets a fixed height. Here is what I have (with height in title)

CSS

.header {
    background-color: #ffff00;
    border: 1px solid black;
    position: fixed;
    height: 100px;
    top: 0;
    left: 0;
    right: 0;
    z-index: 2;
}

.content {
    background-color: #cccccc;
    border: 1px solid black;
    position: absolute;
    top: 100px;
    left: 0;
    right: 0;
    bottom: 0;
    overflow: auto;
    height: 100%;
}

http://jsfiddle.net/TBnqw/2302/

- ? , Javascript, CSS, , , -, .

!

+4
1

: http://jsfiddle.net/TBnqw/2304/

.

javascript, - :

header. , - , . bottom section . , .

+1

All Articles