offsetTop
offsetTop returns the position of the current element relative to the top of the offsetParent node.
Syntax
topPos = element.offsetTop
Parameters
topPos is the number of pixels from the top of the parent element.
Example
d = document.getElementById("div1"); topPos = d.offsetTop; if (topPos > 10 ) { // object it offset less // than 10 pixels in its parent }
Notes
Specification
Netscape Communications http://developer.netscape.com |