ww = 200;
hh = 50;
function show(object,evnt,h,v) {
     if (document.layers && document.layers[object] != null) {
		x = evnt.pageX;
		y = evnt.pageY;
	 }
     else if (document.all) {
		x = evnt.clientX;
		y = evnt.clientY;
		
	}
	if (h>0 && v>0) {
 		reposition(object,h,v);
	} else {
    	reposition(object,x,y);
    }
     if (document.layers && document.layers[object] != null) {
         document.layers[object].zIndex = 0;
         document.layers[object].visibility = 'visible';
     }
     else if (document.all) {
         document.all[object].style.zIndex = 0;
         document.all[object].style.visibility = 'visible';
	}
 }
 function hide(object) {
     if (document.layers && document.layers[object] != null)
         document.layers[object].visibility = 'hidden';
     else if (document.all)
         document.all[object].style.visibility = 'hidden';
 }

 function reposition(object,x,y) {
  	y=440;
	
// 	 alert("x = "+x+" y = "+y+" x = "+window.innerWidth+" y = "+window.innerHeight+
// 	 " xoff = "+pageXOffset+" yoff = "+pageYOffset);
     if (document.layers && document.layers[object] != null) {
	 	x=( (window.innerWidth * 33)/100 ) -200;
     	 if ((x + ww) > window.innerWidth) x = -ww +window.innerWidth;
     	 if ((y  + hh) > window.innerHeight +pageYOffset) y = -hh +window.innerHeight +pageYOffset;
         document.layers[object].left = x;
         document.layers[object].top = y;
     }
     else if (document.all) {
	 	x=(((document.body.clientWidth)*33)/100) - 200;
         document.all[object].style.posLeft = x ;
         document.all[object].style.posTop = y ;
     }
 }

