// quick tooltip script slapped together by hugh

var tipHandler = null;

function showtip(html,xwidth) {
	document.body.appendChild(tooldiv(html,xwidth));
}

function hidetips() {
if(tipHandler!=null) {
	document.body.removeChild(tipHandler);
	tipHandler=null;
}}



function tooldiv(html,xwidth) {

	tipHandler=document.createElement("DIV");
	tipHandler.style.position="absolute";
	tipHandler.style.border="solid 1px #364194";
	tipHandler.style.textAlign="left";
	tipHandler.style.maxwidth="50px";
	tipHandler.style.left= (posx + 20) + "px";
	tipHandler.style.top= (posy + 20) + "px";
	tipHandler.style.padding = "2px";

	if(xwidth != parseInt(xwidth)) xwidth=150;
	tipHandler.style.width = xwidth + "px";

	tipHandler.style.fontSize="10px";
	tipHandler.style.background = "#ffffff";

	tipHandler.innerHTML = html;
//tipHandler.firstChild.data = html;

tooldivupdate();

return tipHandler;

}


function tooldivupdate() {
	tipHandler.style.left= (posx + 10) + "px";
	tipHandler.style.top= (posy + 10) + "px";
	if(tipHandler) setTimeout("tooldivupdate()",10);
}

var posx;var posy;

function getMouse(e){

posx=0;posy=0;
var ev=(!e)?window.event:e;//IE:Moz
if (ev.pageX){//Moz
posx=ev.pageX+window.pageXOffset;
posy=ev.pageY+window.pageYOffset;
}
else if(ev.clientX){//IE
posx=ev.clientX+document.body.scrollLeft;
posy=ev.clientY+document.body.scrollTop;
}
else{return false}//old browsers

// do stuff here if needs be.

}

document.onmousemove=getMouse







