function NObjNavigateur(){ //Browsercheck (needed)
	this.ver=navigator.appVersion
	this.agent=navigator.userAgent
	//alert(this.ver+'\n\n'+this.agent);
	this.dom=document.getElementById?1:0
	this.opera5=this.agent.indexOf("Opera 5")>-1
	this.opera=this.agent.indexOf("Opera")>-1
	this.ie=(this.ver.indexOf("MSIE")>-1 && this.dom && !this.opera5)?1:0;
	this.ie4=(document.all && !this.dom && !this.opera5)?1:0;
	this.ie5=(this.ver.indexOf("MSIE 5")>-1 && this.dom && !this.opera5)?1:0;
	this.ie6=(this.ver.indexOf("MSIE 6")>-1 && this.dom && !this.opera5)?1:0;
	this.ie7=(this.ver.indexOf("MSIE 7")>-1 && this.dom && !this.opera5)?1:0;
	this.ie8=(this.ver.indexOf("MSIE 8")>-1 && this.dom && !this.opera5)?1:0;
	this.mac=this.agent.indexOf("Mac")>-1
	this.ff=this.agent.indexOf("Firefox")>-1
	this.ns6=(this.dom && parseInt(this.ver) >= 5) ?1:0;
	this.ns4=(document.layers && !this.dom)?1:0;
	this.ok=((this.ie && !this.ie5 && !this.ie4) || this.ff);
	return this
}
var navigateur=new NObjNavigateur()

function findLI(e) {
	var sOName = e.tagName;
	if (sOName=="LI") return e;
  	else if (sOName=='BODY') return null;
  	else return findLI(e.parentNode);
}

function fnReturnWindowSizes() {
	var scrollH = 0;	// scrollY
	var scrollW = 0;	// scrollX
	var windowH = 0;	// largeur de la fenêtre
	var windowW = 0;	// hauteur de la fenêtre
	// document.doctype n'est pas nul seulement si nous sommes sous FF et
	//qu'une doctype a été définie
	// document.documentElement.clientHeight ne vaut 0 que sous IE et sans doctype ou avec doctype HTML 4.0
	if (document.doctype == null || document.documentElement.clientHeight == 0) {
		// IE -OU- pas de doctype
		// window.innerWidth n'est définie que sous FF
		// les deux paires d'égalité suivantes sont vérifiées sous IE en absence 
		// de doctype
		if (window.innerWidth || (document.body.offsetHeight == document.documentElement.offsetHeight && document.body.offsetWidth == document.documentElement.offsetWidth)) {
			// (A)
			// Firefox ou IE sans doctype -OU- IE avec doctype HTML 4.0
			scrollH = document.body.scrollTop;
			scrollW = document.body.scrollLeft;
			windowH = document.body.clientHeight;
			windowW = document.body.clientWidth;
		}
		else {
			// (B)
			// IE avec doctype XHTML 1.0
			scrollH = document.documentElement.scrollTop;
			scrollW = document.documentElement.scrollLeft;
			windowH = document.documentElement.clientHeight;
			windowW = document.documentElement.clientWidth;
		}
	}
	else {
		// Firefox
		if (document.doctype.publicId.search(/xhtml/i) != -1) {
			// (C)
			// Firefox doctype XHTML 1.0
			scrollH = document.documentElement.scrollTop;
			scrollW = document.documentElement.scrollLeft;
		}
		else {
			// (D)
			// Firefox doctype HTML 4.0
			scrollH = document.body.scrollTop;
			scrollW = document.body.scrollLeft;
		}
	}
	// FireFox
	if (window.innerWidth && window.innerHeight) {
		// (E)
		windowH = window.innerHeight;
		windowW = window.innerWidth;
	}
	return Array(windowW,windowH,scrollW,scrollH);
}

function initSelecteur() {
	if (navigateur.ie6) {
		var oCollDiv = document.getElementsByTagName('DIV')
		if (oCollDiv) {
			for (i=0;i<oCollDiv.length;i++) {
				if (oCollDiv[i].id=='selecteurDHTML1') {
					MenuListCssForIE6(oCollDiv[i],"LI", "",0);
				}
			}
		}
	}
}

function MM_openBrWindow(theURL,winName,features) { //v2.0
  window.open(theURL,winName,features);
}

// FONCTION DE ROLLOVER DE LA SHAREBAR

function sharebar(imageid, imgurl){
var img = document.getElementById(imageid);
	if(img){
	img.src = imgurl;
	}
}


// FONCTION DE POPUP pour quand overlay ne marche pas 01/10/10

function popupsend(url)
{
largeur=600;
hauteur=450;
var left=(screen.width-largeur)/2;
var top=(screen.height-hauteur)/2;
nwin=window.open(url,"ami","top="+top+",left="+left+",width="+largeur+",height="+hauteur+",scrollbars=auto");
nwin.focus();}

