/* Tooltip Script
* Author: Paul Arce
* Purpose: simple script to display a tooltip on mouse rollover or other browser event
* Methods: 	showtip(current, whichDiv) - launches tip; whichDiv specifies div id of the tip content
*			hidetip() - hides tip
* Usage: <a href="#" onMouseover="showtip(this, 'tooltip');" onMouseOut="hidetip();">Test</a> 
*/


/*
 READ THIS NOTE :::::::  READ THIS NOTE :::::::  READ THIS NOTE:::::::  READ THIS NOTE:::::::  READ THIS NOTE

This does not function when CF debug is on.
 
 :::::::  READ THIS NOTE :::::::  READ THIS NOTE :::::::  READ THIS NOTE :::::::  READ THIS NOTE :::::::  READ THIS NOTE
*/


function showtip(current, whichDiv)
{

	if(document.getElementById)
    {
               elm=document.getElementById( whichDiv );
               elml=current;  
               elm.style.height=elml.style.height;
               elm.style.top=parseInt(elml.offsetTop+elml.offsetHeight);
               elm.style.left=parseInt(elml.offsetLeft+elml.offsetWidth+10);
               elm.style.visibility = "visible";
			   elm.style.pixelTop = event.clientY + 10;
			   elm.style.pixelLeft = event.clientX + 10;
    }
}
function hidetip(whichDiv){

if (document.layers)
   {
	elm2 = eval("document." + whichDiv );
    elm2.visibility="hidden";
   }
else
  {
   if(document.getElementById)
     {
      elm.style.visibility="hidden";
     }
  } 
}