Mmmm...I think I've seen one somewhere that does this....Let me google. 
quote:
Method 2: Passing the height of an absolute DIV to its relative parent
If you choose to go with all columns set to absolute, now you have the problem of “bottom-section” overwriting “mid-section”.
The workaround I am currently playing with involves a small script. (It is currently on the clunky side, so for now I’m using the CSS-only method above.) The trick is to use the onload event handler in the <body> tag to trigger a little script that reads the height of “mid-col-2” and passes it to “mid-section.” This forces “bottom-section” to start further down the page where it’s supposed to.
The following scripting is bare minimum. (It would be more elegant to have a script that walks the document’s DOM tree, applying itself to every container of a certain type. In this way you might pass the height of the longest column instead of arbitrarily passing only “mid-col-2” and you could perform the transfer to any number of relative container DIVs.) If a clever JavaScripter wants to finish the job, I’d be obliged. In the mean time, here’s the little hack:
function inherit(objidParent,objidChild,objidGrandchild) {
if (document.layers) {
alert('sorry, no pretty layouts for netscape 4');
}
else if (document.getElementById) {
Parent = document.getElementById(objidParent);
Child = document.getElementById(objidChild);
Grandchild = document.getElementById(objidGrandchild);
Parent.style.height = Child.offsetHeight + 'px';
Grandchild.style.display = 'block';
return true
}
}
From: http://www.alistapart.com/articles/flexiblelayouts/