Javascript Reference
Categories: document

javascript document elementFromPoint( )

@March 15, 2008, 1:22 a.m.
elementFromPoint( ) Firefox/Netscape/NN n/a IE 4 Chrome/Safari/DOM n/a

elementFromPoint(x, y)

Returns a reference to the object directly underneath the pixel coordinates specified by the x (horizontal) and y (vertical) parameters. For an element to be recognized, it must be capable of responding to mouse events. Also, if more than one element is positioned in the same location, the element with the highest zIndex value or, given equal zIndex values, the element that comes last in the source code order is the one returned.

 
Parameters
 
x

Horizontal pixel measure relative to the left edge of the window or frame.

y

Vertical pixel measure relative to the top edge of the window or frame.

 
Returned Value

Element object reference.


Powered by Linode.