// Pub d'intro
function showsup()
	{
	if(document.getElementById && ScanCookie("supersticiel")==0)
		{
		document.getElementById("pub").style.width = larg;
		document.getElementById("pub").style.height = haut;
		document.getElementById("pub").innerHTML = html_haut+html_mil+html_bas;
		setTimeout("closeSup()",30000);
		CreationCookie("supersticiel",false);
		}
	}

function closeSup()
	{
	if(document.getElementById)
		{
		document.getElementById("pub").style.width = 1;
		document.getElementById("pub").style.height = 1;
		document.getElementById("pub").innerHTML = '';
		}
	}

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(2005,10,09);
		dateExp = dateExp.toGMTString();
		ifpermanent = '; expires=' + dateExp + ';';
		}
	else
		ifpermanent = '';
	document.cookie = nom + '=' + escape(valeur) + ifpermanent;
	}


if(document.all)
	{
	larg = document.body.clientWidth;
	haut = document.body.clientHeight;
	}
else
	{
	larg = screen.width;
	haut = screen.height;
	}
	
html_haut = "<TABLE WIDTH="+larg+" HEIGHT="+haut+"><TR><TD VALIGN=top ALIGN=center BACKGROUND=Images/grille.gif>";
html_bas = "</TD></TR></TABLE>";


html_mil = "<MAP NAME=quillestemis>  <area shape=rect coords=266,254,333,280 HREF=# onClick=\"closeSup();return(false)\"> <area shape=rect coords=43,265,184,286 href=\"Cartes/Contact.php\"></MAP><TABLE WIDTH=600 HEIGHT=595 CELLPADDING=0 CELLSPACING=0 BORDER=0>";
html_mil += "	<TR>";
html_mil += "<TD><IMG SRC=Images/Halloween05.gif BORDER=0 WIDTH=400 HEIGHT=291 HSPACE=0 VSPACE=0 USEMAP=#quillestemis></TD>";
html_mil += "</TR>";
//Ajouter musique
html_mil += "<EMBED src='Images/Halloween05.mp3' autostart loop=true hidden>";
//fin musique
html_mil += "</TABLE>";
var d=new Date;
var j=d.getDate();
var m=d.getMonth()+1;
var y=d.getFullYear();
if ((j>=15) && (j<=29) && (m==10) && (y==2005)) {window.onload = showsup};
