I've been trying to create a layout with the following features:
I found a similar question here: CSS layout with header, footer and multiple 100% min-height content columns
The author solved the problem using a table based layout. I would like to avoid using tables if possible so I can easily hide the outer columns on smaller screens.
Here is the code I have created so far: http://cdpn.io/DqGfp
As you can see in my codepen demo I am almost there. A refresh produces the correct layout in all cases but ideally this should happen on resizing too.
Here are the resizing bugs I'm trying to fix:
I've tried using
$(window).height()
instead of
$(document).height()
but that causes a whole bunch of new bugs.
Any help is VERY MUCH appreciated!
So I figured it out. I needed clear all the forced column heights before recalculating them when the window is resized.
Here's a link to a post about my solution: http://benpearson.com.au/web-development/3-column-fluid-layout-with-header-sticky-footer-and-100-percent-height-columns/
Thanks for the help.