	Nom = navigator.appName;

	if (Nom != 'Microsoft Internet Explorer') {
	alert("Pour visualiser le site, veuillez télécharger IE Tab en cliquant sur OK !");

	window.location.href="navigateur_erreur.htm";

	}


function img_fx(img){
	if(img && img.filters && img.filters[0]){
		img.filters[0].apply();
		img.filters[0].play();


	}
}

sfHover = function() { 

	var sfEls = document.getElementById("containerMenu").getElementsByTagName("LI");
	for (var i=0; i<sfEls.length; i++) {
		sfEls[i].onmouseover=function() {
			this.className+=" sfhover";
		}
		sfEls[i].onmouseout=function() {
			this.className=this.className.replace(new RegExp(" sfhover\\b"), "");
		}
	}
	
 }
 if (window.attachEvent) window.attachEvent("onload", sfHover);


function imprimePage(impDocId)	{ 

	var printDoc = document.all[impDocId.id];
 	w = window.open('',impDocId.id,'width=300px,height=100px,resizable=yes scrollbars=yes toolbar=yes');
	w.document.write( "<html><head><title>Impression</title>\n" );
	w.document.write( "<script language='JavaScript'>\n");
	w.document.write( "function format() {\n");
	w.document.write("document.all['"+impDocId.id+"'].style.overflowY='visible';\n");
	w.document.write("document.all['"+impDocId.id+"'].style.position='relative';\n");
  	w.document.write("document.all['"+impDocId.id+"'].style.top='5px';\n");
  	w.document.write("document.all['"+impDocId.id+"'].style.left='0px';\n");
  	w.document.write("document.all['"+impDocId.id+"'].style.width='700px';\n");
  	w.document.write("document.all['"+impDocId.id+"'].style.height='100%';\n");
  	w.document.write( "self.resizeTo(775,700);\n");
  	w.document.write( "self.focus();\n");
  	w.document.write( "}\n</scri");
	w.document.write( "pt>\n");
	w.document.write( "</head><body leftmargin=20 topmargin=20 marginwidth=0 marginheight=0 onLoad='javascript:format();'> " );
	w.document.write("<font face='Verdana' size='1'>[ F5 pour ouvrir ]</font>&nbsp;&nbsp;&nbsp;<button onclick='JavaScript:window.print();'>Imprimer</button> <br><hr>");
	w.document.write(printDoc.outerHTML);
	w.document.write( "</body></html>" );
	}



function resizePopUp(monImage, monTitre)
    {
	w = window.open('','chargement','width=10px,height=10px');
	w.moveTo(20,20);
	w.document.write( "<html><head><title>"+monTitre+"</title>\n" );
	w.document.write( "<script language='JavaScript'>\n");
	w.document.write( "IE5=NN4=NN6=false;\n");
	w.document.write( "if(document.all)IE5=true;\n");
	w.document.write( "else if(document.getElementById)NN6=true;\n");
	w.document.write( "else if(document.layers)NN4=true;\n");
	w.document.write( "function autoSize() {\n");
	w.document.write( "if(IE5) self.resizeTo(document.images[0].width+9,document.images[0].height+59);\n");
	w.document.write( "else if(NN6) self.sizeToContent();\n");
	w.document.write( "else window.resizeTo(document.images[0].width,document.images[0].height+20);\n");
	w.document.write( "self.focus();\n");
	w.document.write( "}\n</scri");
	w.document.write( "pt>\n");
	w.document.write( "</head><body leftmargin=0 topmargin=0 marginwidth=0 marginheight=0 onLoad='javascript:autoSize();'>" );
	w.document.write( "<center><a href='javascript:window.close();'><img src='"+monImage+"' border=0 alt='"+monTitre+"'></a></center>" );
	w.document.write( "</body></html>" );
	w.document.close();
		}


	var volumeSetting = new Array();
	var currentVolume = 1;
	var mediaPlayer ;


function init_media() {

	var mediaCollection = document.getElementsByTagName('MEDIA'); 	//  MEDIA VIDEO

	for(i=0; i<mediaCollection.length; i++) {
	
	var oAttrObj = mediaCollection[i];
	var oAttr = oAttrObj.attributes;
	var oMediaId = oAttr.getNamedItem("id");
	var MediaId = oMediaId.value;

	if (	document.all[MediaId].currTimeState.isActive) {
	oMedia = MediaId ;
	} else {
	return false;
 	}
	}
}

function volumeArray(vol,visible,id,color) {
	
		this.vol = vol;
		this.visible = visible;
		this.id = id;
		this.color = color;

	}
		

	volumeSetting[0] = new volumeArray('0','visible','led_00','yellow');
	volumeSetting[1] = new volumeArray('10','visible','led_01','yellow');
	volumeSetting[2] = new volumeArray('20','visible','led_02','yellow');
	volumeSetting[3] = new volumeArray('30','visible','led_03','yellow');
	volumeSetting[4] = new volumeArray('40','visible','led_04','lime');
	volumeSetting[5] = new volumeArray('50','visible','led_05','lime');
	volumeSetting[6] = new volumeArray('60','visible','led_06','lime');
	volumeSetting[7] = new volumeArray('70','visible','led_07','red');
	volumeSetting[8] = new volumeArray('80','visible','led_08','red');
	volumeSetting[9] = new volumeArray('100','visible','led_09','red');
	
	
function volumeControl(change,idm) {

	
	if ((change == "decrease") && (currentVolume > 0)) {
				
	document.all[idm].volume = volumeSetting[currentVolume].vol;
	document.all[volumeSetting[currentVolume].id].fillcolor= "#F5F5F5";
	currentVolume = currentVolume-1;
	}

	if ((change == "increase") && (currentVolume < 9)) {
	currentVolume = currentVolume+1;

	document.all[idm].volume = volumeSetting[currentVolume].vol;
	document.all[volumeSetting[currentVolume].id].fillcolor= volumeSetting[currentVolume].color;
	}
	
}

	var bPlayListMade = false;
	

function fnCreatePlayList(oMedia)	{ 

    if(bPlayListMade == false)
    {
        var playCollection = document.all[oMedia].playList;
        for(i=0;i<playCollection.length;i++)
        {
		
            var sElement = "<SPAN onclick='"+"fnGoToTrack(\""+oMedia+"\")'" +	
		" CLASS = 'trackDisplay'>" + playCollection(i).title + "</SPAN>";
		var oDisplaySpan = document.createElement(sElement);
            oDisplaySpan.innerText = playCollection(i).title;
            oShowPlayList.insertBefore(oDisplaySpan);
            var oBr = document.createElement("BR");
            oShowPlayList.insertBefore(oBr);
		
        }
        bPlayListMade = true;
		}
	}

function fnGoToTrack(oMedia) { 

    var playCollection = document.all[oMedia].playList;
    for(i=0;i<playCollection.length;i++)
    {
        if(event.srcElement.innerText == playCollection(i).title)
        {
            playCollection(i).setActive();
        }
    }	
}

function updateFields(oMedia) {

    var aSpans = oShowPlayList.childNodes;
    
    for (i=0; i<aSpans.length; i++)
    {
        aSpans(i).style.color = "black";
		aSpans(i).style.fontWeight = "normal";
        if(aSpans(i).innerText == document.all[oMedia].playList.activeTrack.title)
        {
            aSpans(i).style.color = "red";
			aSpans(i).style.fontWeight = "bold";
        }
    }
   
    oTitle.innerText = document.all[oMedia].playList.activeTrack.title;
    oAuthor.innerText = document.all[oMedia].playList.activeTrack.author;
    oAbstract.innerText = document.all[oMedia].playList.activeTrack.abstract;
    oCopyright.innerText = document.all[oMedia].playList.activeTrack.copyright;
    // oFilename.innerText =  document.all[oMedia].playList.activeTrack.src;
	
}

function clearFields(){
    oTitle.innerText = " ";
    oAuthor.innerText = " ";
    oAbstract.innerText = " ";
    oCopyright.innerText = " ";
    // oFilename.innerText = "";
}

// Automatically attach a listener to the window onload, to convert the trees
addEvent(window,"load",convertTrees);

// Utility function to add an event listener
function addEvent(o,e,f){
	if (o.addEventListener){ o.addEventListener(e,f,true); return true; }
	else if (o.attachEvent){ return o.attachEvent("on"+e,f); }
	else { return false; }
}

// utility function to set a global variable if it is not already set
function setDefault(name,val) {
	if (typeof(window[name])=="undefined" || window[name]==null) {
		window[name]=val;
	}
}

// Full expands a tree with a given ID
function expandTree(treeId) {
	var ul = document.getElementById(treeId);
	if (ul == null) { return false; }
	expandCollapseList(ul,nodeOpenClass);
}

// Fully collapses a tree with a given ID
function collapseTree(treeId) {
	var ul = document.getElementById(treeId);
	if (ul == null) { return false; }
	expandCollapseList(ul,nodeClosedClass);
}

// Expands enough nodes to expose an LI with a given ID
function expandToItem(treeId,itemId) {
	var ul = document.getElementById(treeId);
	if (ul == null) { return false; }
	var ret = expandCollapseList(ul,nodeOpenClass,itemId);
	if (ret) {
		var o = document.getElementById(itemId);
		if (o.scrollIntoView) {
			o.scrollIntoView(false);
		}
	}
}

// Performs 3 functions:
// a) Expand all nodes
// b) Collapse all nodes
// c) Expand all nodes to reach a certain ID
function expandCollapseList(ul,cName,itemId) {
	if (!ul.childNodes || ul.childNodes.length==0) { return false; }
	// Iterate LIs
	for (var itemi=0;itemi<ul.childNodes.length;itemi++) {
		var item = ul.childNodes[itemi];
		if (itemId!=null && item.id==itemId) { return true; }
		if (item.nodeName == "LI") {
			// Iterate things in this LI
			var subLists = false;
			for (var sitemi=0;sitemi<item.childNodes.length;sitemi++) {
				var sitem = item.childNodes[sitemi];
				if (sitem.nodeName=="UL") {
					subLists = true;
					var ret = expandCollapseList(sitem,cName,itemId);
					if (itemId!=null && ret) {
						item.className=cName;
						return true;
					}
				}
			}
			if (subLists && itemId==null) {
				item.className = cName;
			}
		}
	}
}

// Search the document for UL elements with the correct CLASS name, then process them
function convertTrees() {
	setDefault("treeClass","mktree");
	setDefault("nodeClosedClass","liClosed");
	setDefault("nodeOpenClass","liOpen");
	setDefault("nodeBulletClass","liBullet");
	setDefault("nodeLinkClass","bullet");
	setDefault("preProcessTrees",true);
	if (preProcessTrees) {
		if (!document.createElement) { return; } // Without createElement, we can't do anything
		uls = document.getElementsByTagName("ul");
		for (var uli=0;uli<uls.length;uli++) {
			var ul=uls[uli];
			if (ul.nodeName=="UL" && ul.className==treeClass) {
				processList(ul);
			}
		}
	}
}

// Process a UL tag and all its children, to convert to a tree
function processList(ul) {
	if (!ul.childNodes || ul.childNodes.length==0) { return; }
	// Iterate LIs
	for (var itemi=0;itemi<ul.childNodes.length;itemi++) {
		var item = ul.childNodes[itemi];
		if (item.nodeName == "LI") {
			// Iterate things in this LI
			var subLists = false;
			for (var sitemi=0;sitemi<item.childNodes.length;sitemi++) {
				var sitem = item.childNodes[sitemi];
				if (sitem.nodeName=="UL") {
					subLists = true;
					processList(sitem);
				}
			}
			var s= document.createElement("SPAN");
			var t= '\u00A0'; // &nbsp;
			s.className = nodeLinkClass;
			if (subLists) {
				// This LI has UL's in it, so it's a +/- node
				if (item.className==null || item.className=="") {
					item.className = nodeClosedClass;
				}
				// If it's just text, make the text work as the link also
				if (item.firstChild.nodeName=="#text") {
					t = t+item.firstChild.nodeValue;
					item.removeChild(item.firstChild);
				}
				s.onclick = function () {
					this.parentNode.className = (this.parentNode.className==nodeOpenClass) ? nodeClosedClass : nodeOpenClass;
					return false;
				}
			}
			else {
				// No sublists, so it's just a bullet node
				item.className = nodeBulletClass;
				s.onclick = function () { return false; }
			}
			s.appendChild(document.createTextNode(t));
			item.insertBefore(s,item.firstChild);
		}
	}
}


