var msg_no = false;
var msg_init = true;
var msg_local;

////////////////////////////////////////////////////////////////////////////////////////////////////
	function js_dayName(n) 
	{
		var days = Array("lundi", "mardi", "mercredi", "jeudi", "vendredi", "samedi", "dimanche");
		return days[n];
	}
		
////////////////////////////////////////////////////////////////////////////////////////////////////
	function js_monthName(n) 
	{
		var months = Array("janvier", "février", "mars", "avril", "mai", "juin", "juillet", "août", "septembre", "octobre", "novembre", "décembre");
		return months[n];
	}
	

////////////////////////////////////////////////////////////////////////////////////////////////////
	function js_time() 
	{
		var maintenant = new Date();

		var jour = maintenant.getDate();
		var mois = maintenant.getMonth() + 1;
		var annee = maintenant.getFullYear();
		
		var heure = maintenant.getHours();
		var minute = maintenant.getMinutes();
		
		var zero_heure = "";
		
	
		var zero_minute = "";
		
		if (heure < 10) { zero_heure = "0"; }
		if (minute < 10) { zero_minute = "0"; }

		document.getElementById('time').innerHTML = zero_heure + heure + "h" + zero_minute + minute ;
		document.getElementById('date').innerHTML = js_dayName(maintenant.getDay()-1) + " " + jour + " " + js_monthName(mois-1) + " " + annee;
		
		window.setTimeout('js_time()', 1000);
	}
	
////////////////////////////////////////////////////////////////////////////////////////////////////
	function js_window(width, height) 
	{ 
		window.outerWidth = width;
		window.outerHeight = width;
	}

////////////////////////////////////////////////////////////////////////////////////////////////////
	function js_dem(abc, xyz) 
	{ 
		var tmp = new RegExp('(.*)(MULTIPASS)(.*)','g'); 
		var res = abc.replace(tmp,'$1\@$3'); 
		document.write('<a href="mailto:' + res + '">' + xyz + '</a>'); 
	}

////////////////////////////////////////////////////////////////////////////////////////////////////
// The following are necessary for IE7.  When the user pastes a URL into the
	 // location bar, the old definition and values are carried over.  It's no longer
	 // possible to check that one of these vars is undefined.  Define 'em here and check
	 // their value.
	window.onLoad_called = false;
	window.already_loaded = false;

	 function onLoad() {
		if ( typeof window.onLoad_called != "undefined" && window.onLoad_called == true ) {
			return;
		}
		
				if( screen.width < 1024 || screen.height < 768 ) {
			clearLaunchPreviouslyFailedCookie();
			window.location.href = "system_requirements?resolution=unsupported";
		}
				 
		window.onLoad_called = true;
		callJScriptOnLoadHandler();
	 }
////////////////////////////////////////////////////
function checkBrowser()
{	
	this.ver=navigator.appVersion;
	this.dom=document.getElementById?1:0;
	this.ie6=(this.ver.indexOf("MSIE 6")>-1 && this.dom)?1:0;
	this.ie55=((this.ver.indexOf("MSIE 5.5")>-1 || this.ie6) && this.dom)?1:0;
	this.ie5=((this.ver.indexOf("MSIE 5")>-1 || this.ie5 || this.ie6) && this.dom)?1:0;
	this.ie4=(document.all && !this.dom)?1:0;
	this.ns5=(this.dom && parseInt(this.ver) >= 5) ?1:0;
	this.ns4=(document.layers && !this.dom)?1:0;
	this.ie4plus=(this.ie6 || this.ie5 || this.ie4);
	this.ie5plus=(this.ie6 || this.ie5)
	this.bw=(this.ie6 || this.ie5 || this.ie4 || this.ns4 || this.ns5);
	return this;
}
			
bw = new checkBrowser();
			
if (!document.getElementById) 
{
document.getElementById = getObjectById;
}
			
function getObjectById(ID) 
{
	var obj;
	if (bw.dom)
		return document.getElementById(ID);
	else if (bw.ie4)
		return document.all(ID);
	else if (bw.ns4)
		return eval('document.' + ID);
}
			
function getObjectByIdParent(ID) 
{
	var obj;
	if (bw.dom)
		return parent.document.getElementById(ID);
	else if (bw.ie4)
		return parent.document.all(ID);
	else if (bw.ns4)
		return eval('parent.document.' + ID);
}

function cancelBubble(netEvent) 
{
    if (document.all) 
    {
        window.event.cancelBubble = true;
    } 
    else 
    {
        netEvent.cancelBubble = true;
    }
}