[thelist] Returning height of div

Peter-Paul Koch gassinaumasis at hotmail.com
Tue Sep 10 08:17:01 CDT 2002


>Can anyone tell me what is the javascript syntax for ascertaining the
>height and width of a div? This needs to be IE only, and I need to know
>the dimensions when the onload event has fired. The div is dynamically
>populated with text on the server, so the height is not set at any
>point.

document.all['id_of_div'].currentStyle.height

or

document.all['id_of_div'].offsetHeight

Try them and see which one gives the most reliable information.

ppk

_________________________________________________________________
MSN Photos is the easiest way to share and print your photos:
http://photos.msn.com/support/worldwide.aspx




More information about the thelist mailing list