function G(id){return document.getElementById(id);}

var popLoaded=false;



function getIE(e){
	var t=e.offsetTop;
	var l=e.offsetLeft;
	while(e=e.offsetParent){
		t+=e.offsetTop;
		l+=e.offsetLeft;
	}
	return {left:l, top:t}; 
}

function showPop(url,Id){

		var objSha = G("shadowDiv");
		objSha.style.height = document.body.scrollHeight+"px";
		objSha.style.width= document.body.scrollWidth+"px";
		objSha.style.left = 0;
		objSha.style.top = 0;
		
		
		//if(!popLoaded){
 			try{
 				G("ifr").src= url;
 			}catch(e)
 			{
 				document.frames["ifr"].location = url;
 			}
		//}

		var objPop = G("popDiv");
		var sClientWidth = document.body.clientWidth;
		var sClientHeight = document.body.clientHeight;
		var sScrollTop = document.body.scrollTop;
		var sleft = (document.body.clientWidth / 2) - 0;
		var iTop = -80 + (sClientHeight / 2 + sScrollTop) - 0;
		var sTop = iTop > 0 ? iTop : (sClientHeight / 2 + sScrollTop) - 225;
		if(sTop < 1) sTop="20px";
		if(sleft < 1) sleft="20px";
		
		//alert("iTop" +iTop + "  sTop" + sTop);
		
		if(screen.width < 801){

			objPop.style.left = "280px";
			objPop.style.top = -120 + getIE( document.getElementById("point_" + Id ) ).top+"px";
			objPop.style.height = "420px";

		}else if(screen.width > 1024){

			objPop.style.left = "530px";
			objPop.style.top = -120 + getIE( document.getElementById("point_" + Id ) ).top+"px";
			objPop.style.height = "430px";

		}else{		
			
			objPop.style.left = "380px";
			objPop.style.top = -120 + getIE( document.getElementById("point_" + Id ) ).top+"px";
			objPop.style.height = "420px";
		}
		
		objSha.style.display = "";
		objPop.style.display = "";

}

function hidePop(){

		G("popDiv").style.display = "none";
		G("shadowDiv").style.display = "none";

		
}
