function getAbsOffsetLeft(element) {
    if (element.offsetParent) return element.offsetLeft + getAbsOffsetLeft(element.offsetParent);
        else return element.offsetLeft;
}
function getAbsOffsetTop(element) {
    if (element.offsetParent) return element.offsetTop + getAbsOffsetTop(element.offsetParent);
        else return element.offsetTop;
}

function getStyleValue(id, iePropName, mozPropName){
	var el = document.getElementById(id);
	if (el.currentStyle) { //if IE5+
		return el.currentStyle[iePropName];
	} else if (window.getComputedStyle) { //if NS6+
		var elstyle = window.getComputedStyle(el, "");
		return elstyle.getPropertyValue(mozPropName);
	}
}
