ie4 = ((navigator.appName == "Microsoft Internet Explorer") && (parseInt(navigator.appVersion) >= 4 ))
ns4 = ((navigator.appName == "Netscape") && (parseInt(navigator.appVersion) >= 4 ))

if (ns4) {
    // layerRef="document.layers";
	layerRef="document.getElementById(\"";
    styleRef="\").style";
} else {
    layerRef="document.all[\"";
    styleRef="\"].style";
}       

function afficheCalque(calque)
{
  eval(layerRef + '' + calque +'' + styleRef + '.visibility = "visible"');
}

function cacheCalque(calque)
{
  eval(layerRef + '' + calque +'' + styleRef + '.visibility = "hidden"');
}
function cacheBandeau()
{
	cacheCalque("smenu_experts");
	cacheCalque("smenu_newsletter");
	cacheCalque("smenu_presse");
}

var fenetreOuverte;

function ouvre_fenetre(theURL,winName,features) { //v2.0
	fenetreOuverte=window.open(theURL, winName, features);
	fenetreOuverte.focus();
}
function fermerFenetreOuverte() {
	fenetreOuverte.close();
}

function verif_email(objForm,objChamp,objChampValeur)
// ----------------------------------------------------------------------------
// verif_email.js	version 1.1
//  Justin Wui Ken Thoo (Allaire)
// ----------------------------------------------------------------------------
{	
	// alert (objForm+' '+objChamp+' '+objChampValeur);
	var s = objChampValeur;
	var ok = 1;
	// Un email comporte plus de 7 caractères
	if ((s.length < 7)){
		ok = 0;
	}
	// Un @ et au moins un caractere devant
	var at = s.indexOf('@');
	if (at < 1){
		ok = 0;
	}
	// Pas plus d'un @
	if (at != s.lastIndexOf('@')){
		ok = 0;
	}
	// Un . apres le @ ; au moins un caractere entre le @ et le . ; 2 à 5 caracteres apres le .
	if ((s.lastIndexOf('.') < (at+2)) || (s.lastIndexOf('.') > (s.length-3)) || (s.lastIndexOf('.') < (s.length-6))){
		ok = 0;
	}
	// Vérification pas de caracteres bizarres sauf '
	if ((s.indexOf(',') != -1) || 
		(s.indexOf(' ') != -1) || 
		(s.indexOf(';') != -1) || 
		(s.indexOf(':') != -1) || 
		(s.indexOf('?') != -1) || 
		(s.indexOf('/') != -1)  || 
		(s.indexOf('\\') != -1) || 
		(s.indexOf('"') != -1)  || 
		(s.indexOf("'") != -1)  || 
		(s.indexOf('[') != -1) || 
		(s.indexOf(']') != -1) ||
		(s.indexOf('`') != -1) ||
		(s.indexOf('!') != -1) ||
		(s.indexOf('#') != -1) ||
		(s.indexOf('$') != -1) ||
		(s.indexOf('%') != -1) ||
		(s.indexOf('^') != -1) ||
		(s.indexOf('&') != -1) ||
		(s.indexOf('*') != -1) ||
		(s.indexOf('(') != -1) ||
		(s.indexOf(')') != -1) ||
		(s.indexOf('=') != -1) ||
		(s.indexOf('+') != -1) ||
		(s.indexOf('}') != -1) ||
		(s.indexOf('{') != -1) ||
		(s.indexOf('|') != -1) ||
		(s.indexOf('<') != -1) ||
		(s.indexOf('>') != -1)  )
		{
		ok = 0;
	}
	if (s == '')
	{ok=1;}
	if (ok == 1){
		return true;
	} else {
		return false;
	}
}


function openPictureWindow_Fever(imageName,imageWidth,imageHeight,alt,posLeft,posTop) {
	newWindow = window.open("","newWindow","width="+imageWidth+",height="+imageHeight+",left="+posLeft+",top="+posTop);
	newWindow.document.open();
	newWindow.document.write('<html><title>'+alt+'</title><body bgcolor="#FFFFFF" leftmargin="0" topmargin="0" marginheight="0" marginwidth="0" onBlur="self.close()">'); 
	newWindow.document.write('<img src='+imageName+' width='+imageWidth+' height='+imageHeight+' alt='+alt+'>'); 
	newWindow.document.write('</body></html>');
	newWindow.document.close();
	newWindow.focus();
}
