

function detect(){

	var ns = (navigator.appName =="Netscape")? true:false;
	var ie = (navigator.appName == "Microsoft Internet Explorer")? true:false;
	if(ie){
		return true;
	}else if(ns){
		return false;
	}
}
function detectBrowser(){
	alert (navigator.appName);
	var ns = (navigator.appName =="Netscape")? true:false;
	var ie = (navigator.appName == "Microsoft Internet Explorer")? true:false;
	if(ie){
		if (navigator.appVersion.charAt(0) >= '4')
		{
			return "ie";
		}
	}else if(ns){
		if ((navigator.appVersion.charAt(0) >= '5') || 
        ((navigator.appVersion.charAt(0) == '4') && (navigator.appVersion.charAt(2) >= '1')) ||
        ((navigator.appVersion.charAt(0) == '4') && (navigator.appVersion.charAt(2) == '0') && (navigator.appVersion.charAt(3) >= '7')))
		{
			return "ns";
		}
	}

	return "";
}

//

function modifon(bouton){
	bouton.style.background='#C0C0C0';
	bouton.style.color='#333333';
	//this.style.background='#333333';this.style.color='#FFCC00';
}

function modifoff(bouton){
	//this.style.background='#C0C0C0';this.style.color='#333333';
	bouton.style.background='#000000';
	bouton.style.color='#FFCC00';
}

function popUpStrike(url,vwidth,vheight) {	
		
	var w = vwidth;
	var h = vheight;
	var x = (screen.width - w)/2;
	var y = (screen.height - h)/2;			
			
	popupWin = window.open(url, 'remote',  'menubar=no,toolbar=no,location=no,directories=no,status=no,scrollbars=yes,resizable=no,width='+w+',height='+h+',left='+x+',top='+y+'')
}

function popUpRese(url,vwidth,vheight) {	
		
	var w = vwidth;
	var h = vheight;
	var x = (screen.width - w)/2;
	var y = (screen.height - h)/2;			
			
	popupWin = window.open(url, 'remote',  'menubar=yes,toolbar=no,location=no,directories=no,status=no,scrollbars=yes,resizable=no,width='+w+',height='+h+',left='+x+',top='+y+'')
}


function popCarte(url,vwidth,vheight)
{
	var w = vwidth;
	var h = vheight;
	var x = (screen.width - w)/2;
	var y = (screen.height - h)/2;			
	popupWin = window.open(url, '_blank', 'menubar=no,toolbar=no,location=no,directories=no,status=no,scrollbars=no,resizable=no,width='+w+',height='+h+',left='+x+',top='+y+'')
}

function unsec(lien)
{
	if ( (lien) && (lien.protocol=='https:') )
	{
		lien.protocol='http:' ;
		lien.port=80 ;
	}
}

function deSecuriserPage() {

	for (i=0 ; i<document.links.length ; i++)
	{
		if (document.links[i].protocol=='https:')
		{
			document.links[i].protocol='http:' ;
			document.links[i].port=80 ;
		}
	}

}


