This code in index.html (no joomla):
<script>
var left = document.getElementById('zijmenu').offsetHeight;
var right = document.getElementById('container').offsetHeight;
document.write("hoogte linkerkant: ", left, " hoogte rechterkant: ", right);
if (left < right)
{document.getElementById('zijmenu').style.height = right;}
else
{document.getElementById('container').style.height = left;}
</script>
works fine:
<div id="zijmenu" style="height: 232px;">
when I add the same script in the index.php of the template in Joomla 3.3 the result is:
<div id="zijmenu" style="">
document.write works as expected: hoogte linkerkant: 132 hoogte rechterkant: 232
Why doesn't it pick up the style? I can't seem to find the answer anywhere....
Help is appreciated!
Regards Lenneke