function getDimensions()
{  
  if( typeof( window.innerWidth ) == 'number' ) {
    //Non-IE
    browserWidth = window.innerWidth;
    browserHeight = window.innerHeight;
  } else if( document.documentElement &&
      ( document.documentElement.clientWidth || document.documentElement.clientHeight ) ) {
    //IE 6+ in 'standards compliant mode'
    browserWidth = document.documentElement.clientWidth;
    browserHeight = document.documentElement.clientHeight;
  } else if( document.body && ( document.body.clientWidth || document.body.clientHeight ) ) {
    //IE 4 compatible
    browserWidth = document.body.clientWidth;
    browserHeight = document.body.clientHeight;
  }
  //window.alert( 'Width = ' + browserWidth );
 // window.alert( 'Height = ' + browserHeight );
}


function setPage()
{
	getDimensions();
	scrollHeight = parseInt(document.getElementById('Content').scrollHeight);
	//alert(browserHeight);
	
	document.getElementById('Content').style.top = (browserHeight/2 -scrollHeight/2) + "px";
	document.getElementById('Content').style.visibility = "visible"
}


// Detect if the browser is IE or not.
// If it is not IE, we assume that the browser is NS.
var IE = document.all?true:false

// If NS -- that is, !IE -- then set up for mouse capture
if (!IE) document.captureEvents(Event.MOUSEMOVE)

// Set-up to use getMouseXY function onMouseMove
document.onmousemove = getMouseXY;


var tempX = 0
var tempY = 0


function getMouseXY(e) {
  if (IE) { // grab the x-y pos.s if browser is IE
    tempX = event.clientX + document.body.scrollLeft
    tempY = event.clientY + document.body.scrollTop
  } else {  // grab the x-y pos.s if browser is NS
    tempX = e.pageX
    tempY = e.pageY
  }  

  if (tempX < 0){tempX = 0}
  if (tempY < 0){tempY = 0}  
  return true
}



function openThumbOTP(height,width,num)
{
	var imageDiv = document.getElementById('imageDiv');
	imageDiv.innerHTML = '';
	imageDiv.style.height = height + "px";
	imageDiv.style.width = width+ "px";
	if(num > 7)
	{
	imageDiv.style.top = tempY - height-20+ "px";
	}
	else
	{
		imageDiv.style.top = tempY + 10 + "px";
	}
	imageDiv.innerHTML = '<img src="images2/otp'+num+'.jpg">';
	imageDiv.style.left= tempX -(width/2) + "px";
	imageDiv.style.display = "block";
	
	}

function hideImage()
{
	var imageDiv = document.getElementById('imageDiv');
	imageDiv.style.display = "none";

}