function ScanCookie(variable)
	{
	cook = document.cookie;
	variable += "=";
	place = cook.indexOf(variable,0);
	if (place <= -1)
		return("0");
	else
		{
		end = cook.indexOf(";",place)
		if (end <= -1)
			return(unescape(cook.substring(place+variable.length,cook.length)));
		else
			return(unescape(cook.substring(place+variable.length,end)));
		}
	}

function CreationCookie(nom,valeur,permanent)
	{
	if(permanent)
		{
		dateExp = new Date(2020,11,11);
		dateExp = dateExp.toGMTString();
		ifpermanent = '; expires=' + dateExp + ';';
		}
	else
		ifpermanent = '';
	document.cookie = nom + '=' + escape(valeur) + ifpermanent;
	}


function openpopup(fichier){
var left = (screen.width  / 2) - (210  / 2);
var top  = (screen.height / 2) - (150 / 2);
if(ScanCookie("dejapopup")==0)
	{
	window.open(fichier,'popup','height=380,width=340,scrollbars=yes,status=no,toolbar=no,menubar=no,location=no,directories=no,alwaysRaised=no,resizable=no,top='+top+',left='+left);
	CreationCookie("dejapopup","oui",false)
	}
}