function getScrollWidth()
{
   var w = window.pageXOffset ||
           document.body.scrollLeft ||
           document.documentElement.scrollLeft;
           
   return w ? w : 0;
}

function getScrollHeight()
{
   var h = window.pageYOffset ||
           document.body.scrollTop ||
           document.documentElement.scrollTop;
           
   return h ? h : 0;
}

function showtip(current,e,text)
{
	if (document.layers) // Netscape 4.0+
	{
		theString="<DIV CLASS='ttip'>"+text+"</DIV>";
		document.tooltip.document.write(theString);
		document.tooltip.document.close()
		document.tooltip.left=e.pageX+14
		document.tooltip.top=e.pageY+2
		document.tooltip.visibility="show"
	}
	else
	{
		if(document.getElementById) // Netscape 6.0+ and Internet Explorer 5.0+
		{
			elm=document.getElementById("tooltip")
			elml=current
			elm.innerHTML=text
			elm.style.top=(getScrollHeight() + parseInt(e.clientY) + 10) + 'px' //parseInt(elml.offsetTop+elml.offsetHeight)
			elm.style.left=(getScrollWidth() + parseInt(e.clientX) + 10) + 'px'//parseInt(elml.offsetLeft+elml.offsetWidth+10)
			elm.style.visibility = "visible"
		}
	}
}

function hidetip(){
	if (document.layers) // Netscape 4.0+
	{
		document.tooltip.visibility="hidden"
	}
	else
	{
		if(document.getElementById) // Netscape 6.0+ and Internet Explorer 5.0+
		{
			elm.style.visibility="hidden"
		}
	}
}
