if you paste this in a html then view in your browser you will see what i am trying to do...
I want the MENU to match the height of the CONTENT, works fine in IE, not in chrome or FF
from what I have read, clientHeight shouldnt matter what browser is used
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html>
<head>
<title>Page</title>
<script type='text/javascript'>
function expandToWindow(element) {
var desiredheight = document.getElementById("content").clientHeight;
if (element.style.height < desiredheight) {
element.style.height = desiredheight
}
}
</script>
</head>
<body onload="expandToWindow(document.getElementById('menu'));">
<div id="menu" style="float: left; width: 235px; background: #ccc;">
menu
</div>
<div id="content" style="float: left; width: 521px; background: #666;">
<p>content</p> <p>content</p> <p>content</p> <p>content</p> <p>content</p> <p>content</p> <p>content</p> <p>content</p> <p>content</p> <p>content</p> <p>content</p> <p>content</p> <p>content</p> <p>content</p> <p>content</p> <p>content</p> <p>content</p> <p>content</p> <p>content</p> <p>content</p> <p>content</p> <p>content</p> <p>content</p> <p>content</p> <p>content</p> <p>content</p> <p>content</p> <p>content</p>
</div>
<div id="links" style="float: left; width: 31px; background: #f00;">
<pre>
s
i
d
e
b
a
r
</pre>
</div>
</body>
</html>