Feedback on: irt.org FAQ Knowledge Base Q1063
Worth:
Worth reading
Length:
Too short
Comments:
Hi there, I've attemped to run the following code in both NS 4.7 and IE 5.0. In NS it works fine, but in IE, instead of displaying the width/height of the layer, it displays empty spaces. Is there any chance that Microsoft have altered the DOM for IE5, and if so, how could I find the width/height of a layer in IE5?
Thanks for your time, and a great site.
<BODY onLoad="textWidth()">
<SCRIPT LANGUAGE="JavaScript"></SCRIPT>
<DIV ID="myId" STYLE="position:absolute;">
How wide<BR>
and how<BR>
high is<BR>
this <BR>
layer<BR>
</DIV>
Length:
Just right
Comments:
Got it! For IE its:
document.all['layer'].clientHeight
document.all['layer'].clientWidth
:-)