Return to Snippet

Revision: 5066
at February 8, 2008 11:08 by otaqui


Initial Code
function getAbsolutePosition( eElement )
{
	var oReturn = { x:0, y:0 }
	while ( eElement != null )
	{
		oReturn.x += oElement.offsetLeft;
		oReturn.y += oElement.offsetTop;
		oElement = oElement.offsetParent;
	}
	return oReturn;
}

Initial URL

                                

Initial Description

                                

Initial Title
getAbsolutePosition

Initial Tags
javascript, textmate

Initial Language
Other