
isIE=document.all;
isNN=!document.all&&document.getElementById;
var IfrRef = document.getElementById('DivShim');
var left;
function virtualPopup(url,largeur,hauteur,id,top,top2,left){	
   this.url = url;
   this.largeur = largeur;
   this.hauteur = hauteur;
   this.left = left;
   this.top = top;
   this.top2 = top2;
   this.id = id;
   this.show = showVPop;
   this.hide = hideVPop;

}

function showVPop(){
var dgi = document.getElementById(this.id).style; 
var dgi3 = document.getElementById('if'+this.id).style; 
var dgi2 = document.getElementById(this.id); 
var IfrRef = document.getElementById('DivShim');
var hfix = !document.all && document.getElementById?this.hauteur:this.hauteur;
var bfix = !document.all && document.getElementById?this.largeur:this.largeur;
dgi.width=bfix+"px";
dgi.height=hfix+"px";
if( this.left != undefined)
	{
	dgi.left = (((document.body.clientWidth-this.largeur)/2)-152)+"px";
	}
else
	{
	dgi.left = ((document.body.clientWidth-this.largeur)/2)+"px";
	}
dgi.top = !document.all && document.getElementById?this.top2+"px":this.top+"px";
dgi.backgroundColor='white';
dgi.display="block";
IfrRef.style.width = dgi2.offsetWidth;
IfrRef.style.height = dgi2.offsetHeight;
IfrRef.style.top = dgi.top;
IfrRef.style.left = dgi.left;
IfrRef.style.zIndex = dgi.zIndex - 1;
IfrRef.style.display = "block";
var tmp = "if"+this.id;
document.getElementById(tmp).src=this.url;
document.getElementById(tmp).style.width=bfix+"px";
document.getElementById(tmp).style.height=hfix+"px";
}

function hideVPop(){
	window.parent.document.getElementById('redirectlayer').style.display='none';
	void(0);
}

function fixScrollBug()
{
	if(document.getElementById('redirectlayer'))
	{
		if(document.getElementById('redirectlayer').style.display=='block')
		{
			document.getElementById('redirectlayer').style.display='none';
			void(0);
			document.getElementById('redirectlayer').style.display='block';
			void(0);
		}else
		{
			document.getElementById('redirectlayer').style.display='none';
			void(0);
		}
	}
}

function fixResize()
{
	if(lcmredirectow == undefined)
	{
		return;
	}
	if(document.getElementById('redirectlayer').style.width && lcmredirectow.left == undefined)
	{	
	var tmp = document.getElementById('redirectlayer').style.width;
	tmp = tmp.substr(0,tmp.length-2);
	tmp = parseInt(tmp);
	document.getElementById('redirectlayer').style.left= ((document.body.clientWidth-tmp)/2)+1+"px";
	}
	else
	{
		document.getElementById('redirectlayer').style.left = (((document.body.clientWidth-lcmredirectow.largeur)/2)-164)+"px";
	}
	
	
}
window.onscroll = fixScrollBug;
window.onresize = fixResize;