var NS4 = (document.layers) ? 1 : 0;
var IE = (document.all) ? 1 : 0;
var NS = document.getElementById&&!document.all;
var style = ((NS4 && document.test) || IE) ? 1 : 0;
var timerID = null;

	function showObject(frame, obj) {
		var obj_path;
		if (NS4) {
			obj_path = eval(frame + ".document." + obj);
			obj_path.visibility = "show";
		}
		if (IE) { 
			obj_path = eval(frame + ".document.all." + obj);
			obj_path.style.visibility = "visible";
		}
		if (NS) {
			obj_path = eval(frame + ".document.getElementById('"+obj+"')");
			obj_path.style.visibility = "visible";
		}
	}
	function hideObject(frame, obj) {
		var obj_path;
		if (NS4) {
			obj_path = eval(frame + ".document." + obj);
			obj_path.visibility = "hide";
		}
		if (IE) {
			obj_path = eval(frame + ".document.all." + obj);
			obj_path.style.visibility = "hidden";
		}
		if (NS) {
			obj_path = eval(frame + ".document.getElementById('"+obj+"')");
			obj_path.style.visibility = "hidden";
		}
	}

	function changeImg(idImg,nameImg) {
		img = eval("document." + idImg);
		img.src = nameImg;
		//fleche=findObj("FlecheMenu")
		//fleche.style.visibility='visible';
	}

	function resizePage(tx,ty) {
		if (navigator.appName == "Netscape") {
			self.resizeTo((tx-8),(ty-128));
		} else {
			self.resizeTo(tx,ty);
		}
	}

	/*
	Text Link/Image Map Tooltip Script- 
	© Dynamic Drive (www.dynamicdrive.com)
	For full source code, installation instructions,
	100's more DHTML scripts, and Terms Of
	Use, visit dynamicdrive.com
	*/

	if (!document.layers&&!document.all)
		event="test"
	function showtip(current,e,text){
		if (NS4){
			document.tooltip.document.write('<layer bgColor="white" style="border:1px solid black;font-size:12px;">'+text+'</layer>');
			document.tooltip.document.close();
			document.tooltip.left=e.pageX+5;
			document.tooltip.top=e.pageY+5;
			document.tooltip.visibility="show";
		}
		if (IE){
			thetitle=text.split('<br>');
			if (thetitle.length>1){
				thetitles='';
				for (i=0;i<thetitle.length;i++)
					thetitles+=thetitle[i];
				current.title=thetitles;
			}
			else {
				current.title=text;
			}
		}
		if (NS) {
			thetitle=text.split('<br>');
			if (thetitle.length>1){
				thetitles='';
				for (i=0;i<thetitle.length;i++)
					thetitles+=thetitle[i];
				current.title=thetitles;
			}
			else {
				current.title=text;
			}
		}
	}
	function hidetip(){
		if (NS4)
			document.tooltip.visibility="hidden";
	}



/* Paragraphes deroulants */
/*
function doExpand(para,arrow, num, max){
		var frame;
		var para_path;
		var fleche_path;
		frame = 'self'

		// on referme tous les menus
		for(l_k=1;l_k<=max; l_k++) {
			if (NS4) {
				para_path = eval(frame + ".document." + para + l_k);
				fleche_path = eval(frame + ".document." + arrow + l_k);
			}
			if (IE) {
				para_path = eval(frame + ".document.all." + para + l_k);
				fleche_path = eval(frame + ".document.all." + arrow + l_k);
			}
			if (NS) {
				para_path = eval(frame + ".document.getElementById('"+para + l_k +"')");
				fleche_path = eval(frame + ".document.getElementById('"+arrow + l_k +"')");
			}
			para_path.style.display="none";
			fleche_path.src="arrowrt.gif";
		}

		if (NS4) {
			para_path = eval(frame + ".document." + para + num);
			fleche_path = eval(frame + ".document." + arrow + num);
			if (para_path.style.display=="none")
				{para_path.style.display="";fleche_path.src="arrowdn.gif"}
				else
				{para_path.style.display="none";fleche_path.src="arrowrt.gif"}
		}
		if (IE) {
			para_path = eval(frame + ".document.all." + para + num);
			fleche_path = eval(frame + ".document.all." + arrow + num);
			if (para_path.style.display=="none"){para_path.style.display="block";fleche_path.src="arrowdn.gif"}
			else{para_path.style.display="none";fleche_path.src="arrowrt.gif"}
		}
		if (NS) {
			para_path = eval(frame + ".document.getElementById('"+para + num+"')");
			fleche_path = eval(frame + ".document.getElementById('"+arrow + num+"')");
			if (para_path.style.display=="none"){para_path.style.display="";fleche_path.src="arrowdn.gif"}
			else{para_path.style.display="none";fleche_path.src="arrowrt.gif"}
		}
		
		
}
*/
	// fenetre --> contient tous les paramètres possibles
	//                                                     |-> Flags
	function fenetre(url, nom, x, y, largeur, hauteur, ascenseur, changeTaille, barreOutils, barreAdresse, barreEtat, barreMenu, barreLiens) {
		window.open(url, nom, 'left='+x+',top='+y+',width='+largeur+',height='+hauteur+',scrollbars='+ascenseur+',resizable='+changeTaille+',toolbar='+barreOutils+',location='+barreAdresse+',status='+barreEtat+',menubar='+barreMenu+',directories='+barreLiens);
	}
	// popup --> Paramètres limités
	function popup(url, nom, x, y, largeur, hauteur, ascenseur) {
		window.open(url, nom, 'left='+x+',top='+y+',width='+largeur+',height='+hauteur+',scrollbars='+ascenseur+', resizable=1');
	}
