/*<![CDATA[*/
	<!--

function MM_findObj(n, d){ //v4.0
  var p,i,x;  if(!d) d=document; if((p=n.indexOf("?"))>0&&parent.frames.length) { d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);}
  if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i<d.forms.length;i++) x=d.forms[i][n];
  for(i=0;!x&&d.layers&&i<d.layers.length;i++) x=MM_findObj(n,d.layers[i].document);
  if(!x && document.getElementById) x=document.getElementById(n); return x;
}
function MM_showHideLayers(){ //v3.0
  var i,p,v,obj,args=MM_showHideLayers.arguments;
  for (i=0; i<(args.length-2); i+=3) if ((obj=MM_findObj(args[i]))!=null) { v=args[i+2];
    if (obj.style) { obj=obj.style; v=(v=='show')?'visible':(v='hide')?'hidden':v; }
    obj.visibility=v; }
}


///////////////////////////////////
function MM_swapImgRestore() { //v3.0
  var i,x,a=document.MM_sr; for(i=0;a&&i<a.length&&(x=a[i])&&x.oSrc;i++) x.src=x.oSrc;
}

function MM_preloadImages() { //v3.0
  var d=document; if(d.images){ if(!d.MM_p) d.MM_p=new Array();
    var i,j=d.MM_p.length,a=MM_preloadImages.arguments; for(i=0; i<a.length; i++)
    if (a[i].indexOf("#")!=0){ d.MM_p[j]=new Image; d.MM_p[j++].src=a[i];}}
}

function MM_swapImage() { //v3.0
  var i,j=0,x,a=MM_swapImage.arguments; document.MM_sr=new Array; for(i=0;i<(a.length-2);i+=3)
   if ((x=MM_findObj(a[i]))!=null){document.MM_sr[j++]=x; if(!x.oSrc) x.oSrc=x.src; x.src=a[i+2];}
}

/////// menu gauche début

function manageMenu(menuId,show)
{
	if (currentMenu != undefined)
	{
		if(currentMenu != menuId)
		{
			if(document.getElementById('menu' + currentMenu) != undefined)
			{
				document.getElementById('menuArrow' + currentMenu).style.visibility='hidden';
				document.getElementById('menu' + currentMenu).style.display='none';			
				document.getElementById('backgroundCell' + currentMenu).style.background='url(fileadmin/img/menu/spacer.gif)';			
				if((document.getElementById('menu' + currentSection)  != undefined))
				{
					document.getElementById('menu' + currentSection).style.display='none';				
				}
				if(document.getElementById('offsetRow' + currentMenu) != undefined)
				{
					document.getElementById('offsetRow' + currentMenu).style.height='1px';		
				}
				currentSection = undefined;
			}
		}
	}	
	if(show)
	{
		if(document.getElementById('menu' + menuId) != undefined)
		{
			currentMenu = menuId;
			document.getElementById('menuArrow' + currentMenu).style.visibility='visible';
			document.getElementById('menu' + currentMenu).style.display='block';	
			document.getElementById('backgroundCell' + currentMenu).style.background='url(fileadmin/img/menu/fond_menu.gif)';
		}
	}
	else
	{
		document.getElementById('menuArrow' + menuId).style.visibility='hidden';
		document.getElementById('menu' + menuId).style.display='none';
	}	
}

function showSection(sectionId, menuId, position)
{
	if((currentSection != undefined) && (sectionId != currentSection))
	{			
		if(document.getElementById('menu' + currentSection) != undefined)
		{
			document.getElementById('menu' + currentSection).style.display='none';		
			document.getElementById('link' + currentSection).className = 'menuUnselected';
		}
		if(lastPos==1)
		{
			document.getElementById('leftCell' + currentSection).style.background='url(\'fileadmin/img/menu/bg_coin_gauche.gif\')';
			document.getElementById('leftImage' + currentSection).src='fileadmin/img/menu/coin_haut_gauche.gif';
			document.getElementById('middleCell' + currentSection).style.backgroundColor='#E2D4E7';
			document.getElementById('rightCell' + currentSection).style.background='url(\'fileadmin/img/menu/bg_coin_droite.gif\')';
			document.getElementById('rightImage' + currentSection).src='fileadmin/img/menu/coin_haut_droite.gif';
		}
		else if(lastPos == 0)
		{
			document.getElementById('leftCell' + currentSection).style.background='url(\'fileadmin/img/menu/coin_gauche_fonce.gif\')';
			document.getElementById('middleCell' + currentSection).style.backgroundColor='#E2D4E7';
			document.getElementById('rightCell' + currentSection).style.background='url(\'fileadmin/img/menu/coin_droite_fonce.gif\')';
		}
		else if(lastPos == -1)
		{
			document.getElementById('leftCell' + currentSection).style.background='url(\'fileadmin/img/menu/coin_gauche_fonce.gif\')';
			document.getElementById('leftImage' + currentSection).src='fileadmin/img/menu/coin_bas_gauche.gif';
			document.getElementById('middleCell' + currentSection).style.backgroundColor='#E2D4E7';
			document.getElementById('rightCell' + currentSection).style.background='url(\'fileadmin/img/menu/coin_droite_fonce.gif\')';
			document.getElementById('rightImage' + currentSection).src='fileadmin/img/menu/coin_bas_droite.gif';
		}
				
	}
	
	if(document.getElementById('menu' + sectionId) != undefined)
	{
		if(sectionId != currentSection)	
		{						
		
			document.getElementById('offsetRow' + menuId).style.height = '1px';
			menuHeight = parseInt(document.getElementById('menu' + menuId).offsetHeight);		
			document.getElementById('menu' + sectionId).style.display='block';			
			currentSection = sectionId;	
			lastPos = position;
			sectionsHeight = parseInt(document.getElementById('menu' + sectionId).parentNode.offsetHeight);									
			if(sectionsHeight > menuHeight)
			{
				document.getElementById('offsetRow' + menuId).style.height = (sectionsHeight - menuHeight) + 'px';
			}
			else
			{
				document.getElementById('offsetRow' + menuId).style.height = '1px';
			}
		}
	}
	else
	{
		document.getElementById('offsetRow' + menuId).style.height = '1px';
		lastPos = position;
		currentSection = sectionId;
	}					
}

function manageTransition(menuId,position,over)
{
	if((currentSection != undefined) && (currentSection == menuId) && (!over))
	{
		return -1;
	}
	
	if(position == 1)
	{
		if(over)
		{
			document.getElementById('leftCell' + menuId).style.background='url(\'fileadmin/img/menu/coin_gauche1.gif\')';
			document.getElementById('leftImage' + menuId).src='fileadmin/img/menu/coin_haut_gauche_over.gif';
			document.getElementById('middleCell' + menuId).style.backgroundColor='#F3E4F9';
			document.getElementById('rightCell' + menuId).style.background='url(\'fileadmin/img/menu/coin_droite1.gif\')';
			document.getElementById('rightImage' + menuId).src='fileadmin/img/menu/coin_haut_droite_over.gif';						
			document.getElementById('link' + menuId).className='menuSelected';
		}
		else
		{
			document.getElementById('leftCell' + menuId).style.background='url(\'fileadmin/img/menu/bg_coin_gauche.gif\')';
			document.getElementById('leftImage' + menuId).src='fileadmin/img/menu/coin_haut_gauche.gif';
			document.getElementById('middleCell' + menuId).style.backgroundColor='#E2D4E7';
			document.getElementById('rightCell' + menuId).style.background='url(\'fileadmin/img/menu/bg_coin_droite.gif\')';
			document.getElementById('rightImage' + menuId).src='fileadmin/img/menu/coin_haut_droite.gif';
			document.getElementById('link' + menuId).className='menuUnselected';
		}
	}
	else if(position == 0)
	{
		if(over)
		{
			document.getElementById('leftCell' + menuId).style.background='url(\'fileadmin/img/menu/coin_gauche1.gif\')';
			document.getElementById('middleCell' + menuId).style.backgroundColor='#F3E4F9';
			document.getElementById('rightCell' + menuId).style.background='url(\'fileadmin/img/menu/coin_droite1.gif\')';
			document.getElementById('link' + menuId).className='menuSelected';
		}
		else
		{
			document.getElementById('leftCell' + menuId).style.background='url(\'fileadmin/img/menu/coin_gauche_fonce.gif\')';
			document.getElementById('middleCell' + menuId).style.backgroundColor='#E2D4E7';
			document.getElementById('rightCell' + menuId).style.background='url(\'fileadmin/img/menu/coin_droite_fonce.gif\')';
			document.getElementById('link' + menuId).className='menuUnselected';
		}
	}
	else if(position == -1)
	{
		if(over)
		{
			document.getElementById('leftCell' + menuId).style.background='url(\'fileadmin/img/menu/coin_gauche1.gif\')';
			document.getElementById('leftImage' + menuId).src='fileadmin/img/menu/coin_bas_gauche_over.gif';
			document.getElementById('middleCell' + menuId).style.backgroundColor='#F3E4F9';
			document.getElementById('rightCell' + menuId).style.background='url(\'fileadmin/img/menu/coin_droite1.gif\')';
			document.getElementById('rightImage' + menuId).src='fileadmin/img/menu/coin_bas_droite_over.gif';
			document.getElementById('link' + menuId).className='menuSelected';
		}
		else
		{
			document.getElementById('leftCell' + menuId).style.background='url(\'fileadmin/img/menu/coin_gauche_fonce.gif\')';
			document.getElementById('leftImage' + menuId).src='fileadmin/img/menu/coin_bas_gauche.gif';
			document.getElementById('middleCell' + menuId).style.backgroundColor='#E2D4E7';
			document.getElementById('rightCell' + menuId).style.background='url(\'fileadmin/img/menu/coin_droite_fonce.gif\')';
			document.getElementById('rightImage' + menuId).src='fileadmin/img/menu/coin_bas_droite.gif';
			document.getElementById('link' + menuId).className='menuUnselected';
		}
	}
}
monmenuactif="";
timer="";
function manageAffMenu(lobjet, lemode){
	if (lemode){
		monmenuactif = lobjet;
		document.getElementById('menuArrow'+lobjet).style.visibility='visible';

		document.getElementById('menu' + lobjet).style.position="absolute";
		document.getElementById('menu' + lobjet).style.marginTop="-10px";
		document.getElementById('menu' + lobjet).style.zIndex="2";
		document.getElementById('menu' + lobjet).style.display='block';	
		document.getElementById('backgroundCell' + lobjet).style.background='url(fileadmin/img/menu/fond_menu.gif)';
	}else{
		if(currentMenu != lobjet){
		timer=setTimeout("manageCacheMenu("+lobjet+")",300);

		}
	}
}
function manageCacheMenu(lobjet){
	if(currentMenu != lobjet){
		monmenuactif = "";
		document.getElementById('menuArrow'+lobjet).style.visibility='hidden';
		
		document.getElementById('menu' + lobjet).style.display='none';	
		document.getElementById('backgroundCell' + lobjet).style.background='url(none)';
	}
}
function manageAffSMenu(lobjet, lemode ){
	if (lemode){
		clearTimeout(timer);
	}else{
		timer=setTimeout("manageCacheMenu("+lobjet+")",100);
	}
	
}
/////// menu gauche fin 
/////// menu gauche V2
function ActiverMenu(lobjet, laction, leniveau){
	leparent= leniveau -1 ;
	if (laction){
		lobjet.lastChild.style.position="absolute";
		lobjet.lastChild.style.left="0px";
		if (lobjet.offsetTop + 153 == lobjet.lastChild.offsetTop){
			posi=lobjet.offsetTop + 153 + 20;
			lobjet.lastChild.style.top= posi +"px";
		}
		lobjet.lastChild.style.zIndex="2";
		lobjet.className="menuGniv"+leparent+"Actif";
	}else{
		lobjet.lastChild.style.position="relative";
		lobjet.lastChild.style.zIndex="0";
		lobjet.className="menuGniv"+leparent;
	}

}
/////// menu gauche V2 fin 
// ********* recherche***************************/
/**************************************************/

function startsearchsite() {
	var value_recherche = document.searchform.requete.value;
			
		if ((value_recherche.length<2) || (value_recherche=="Mots-clés ici") || (value_recherche=="et") || (value_recherche =="ou") || (value_recherche =="and") || (value_recherche =="or")|| (value_recherche =="et ou") || (value_recherche =="ou et") || (value_recherche =="and et ") || (value_recherche =="and or") || (value_recherche =="or and")) {
			
					if((value_recherche.length<2) || (value_recherche=="Mots-clés ici"))
					{
					alert('Pour effectuer une recherche, vous devez d\'abord saisir au moins deux caractères!');
					}
					else  
					{
					alert('le mot choisi est un mot reservé, Veuillez choisir un autre!');
					}
			
			document.searchform.requete.focus();
			return false;
	    }
 	    else{
			return true;
		}
	
}
/********** fin recherche *********************/

//********* popup ***************************/
function popup(page) {
	// ouvre une fenetre sans barre d'etat, ni d'ascenceur
	
	window.open(page,'popup','width=320,height=230,toolbar=no,scrollbars=auto,resizable=no');	 
}
//********* fin popup ***************************/


/********** impression*********************/

function RemoveDivByClass(class_parent,id_child){
var DIVcoll = document.getElementsByTagName("DIV"), hiddenDivs = new Array();
for (LC = 0; LC < DIVcoll.length; LC ++) {
if (DIVcoll[LC].className==class_parent){DIVcoll[LC].removeChild(document.getElementById(id_child)); }
//alert(Id);
}
}
function ReturnDivByClass(class_parent){
var DIVcoll = document.getElementsByTagName("DIV"), hiddenDivs = new Array();
for (LC = 0; LC < DIVcoll.length; LC ++) {
if (DIVcoll[LC].className==class_parent){return DIVcoll[LC] }
 
}
}
function divExistsId(id1){
var DIVcoll = document.getElementsByTagName("DIV"), hiddenDivs = new Array();
for (LC = 0; LC < DIVcoll.length; LC ++) {
if (DIVcoll[LC].id==id1)return true; 
else
return false;
 
}
}

function print_test(){

  	var Ilest  = new Date();
	Heures     = Ilest.getHours();
	Minutes    = Ilest.getMinutes();
	Secondes   = Ilest.getSeconds();
	
	var Today = new Date;
	Jour = Today.getDate();
	temp1 = ((Jour < 10) ? "0" : "") ;	
	Mois = (Today.getMonth())+1;
	temp2 = ((Mois < 10) ? ".0" : ".") ;
	Annee = Today.getYear();
	

 
var id="1";
if (document.location.href.indexOf("?id=")>0){
id=document.location.href.split("?id=")[1].split("&")[0];
}
 
//Traitement particulier de l'impression des pages contenant des listes
if (this.location.href.indexOf("&print=1")>0){
	
//PréTraitement sur les div de la page parente pour générer la page d'impression
				document.getElementById("zone-texte").removeChild(document.getElementById("menu-gauche"));
				document.getElementById("header").removeChild(document.getElementById("bandeau-recherche"));
if (divExistsId("zone-imprimer"))document.getElementById("zone-texte2").removeChild(document.getElementById("zone-imprimer"));
				document.getElementById("bandeau").removeChild(document.getElementById("menu-haut"));
				RemoveDivByClass("tx-macinasearchbox-pi1","recherche");				
				//ReturnDivByClass("module").innerHTML+='<img src=fileadmin/img/imprimer/fond_image_bas.gif><br><br><br><div align="center"><input id="imprimer" type="button" class="button2" name="imprimer" value="Imprimer" onclick="javascript:print_page()"></div>';			
				RemoveDivByClass("module","mentions");
				ReturnDivByClass("module1").style.backgroundImage ="url(xxx)"; 
document.getElementById("zone-texte2").removeChild(document.getElementById("zone-imprimer"));
//var horodatage_div = document.createElement("div");
//horodatage_div.innerHTML='<div  align="right">Imprimé le '+temp1+Jour+temp2+Mois+"."+String(Annee).substr(2,2)+'</div><div align=right id="boutonimprimer"><br /><br /><input type="button" class="button2" name="imprimer" id="imprimer" value="Imprimer"  onclick="javascript:print_page()"></div>';
//horodatage_div.id="";
//document.getElementById("header").appendChild(horodatage_div);
document.getElementById("header").innerHTML+='<div  id=print align="right">Imprimé le '+temp1+Jour+temp2+Mois+"."+String(Annee).substr(2,2)+'<div align=right id="boutonimprimer"><br /><br /><input type="button" class="button2" name="imprimer" id="imprimer" value="Imprimer"  onclick="javascript:print_page()"></div></div>';

// cas particulier : id=55 > liste filtrée
			if (id==55) {
				document.getElementById("formulaire").removeChild(document.getElementById("formulaire1"));  
				document.getElementById("zone-imprimer2").removeChild(document.getElementById("formulaire")); 
				document.getElementById("zone-imprimer2").removeChild(document.getElementById("pagination")); 				
			
			}
			
			else if (id==58||id==191||id==66) {

			}
//Affichage de la page finale
 ReturnDivByClass("module").style.visibility='visible';
}

}

function Clickheretoprint()
{ 
	var disp_setting="toolbar=no,location=no,directories=no,menubar=no,status=no,"; 
		disp_setting+="scrollbars=yes,width=710, height=600, left=100, top=25"; 
	var docprint=window.open("","",disp_setting);
	if (document.location.href.indexOf("?id=")>0){	
	  var id=document.location.href.split("?id=")[1].split("&")[0];
	  if (id.indexOf("#"))id=id.replace("#","");
	}
	
	  var content_vlue = document.getElementById("zone-imprimer2").innerHTML; 
	
	//cas particulier des Programmes en cours avec passage comme paramètre les valeurs du formulaire de recherche
	if (id==55&&this.location.href.indexOf("&print=1")<0) {
	docprint.open('index.php?id=55&print=1&select1='+document.form_select.select1.value+'&select2='+document.form_select.select2.value,"_self","");
	}
	// Cas particulier pour les pages d'id 58,191 et 66 représentant respectivement les Logements pour étudiants et jeunes travailleurs, le locatif social et la FAQ
	else if (id==58||id==191||id==66){
	if (this.location.href.indexOf("&print=1")<0)docprint.open('index.php?id='+id+'&print=1',"_self","");
	}
	
	else{
	
	 
		var Ilest  = new Date();
		Heures     = Ilest.getHours();
		Minutes    = Ilest.getMinutes();
		Secondes   = Ilest.getSeconds();
		
		var Today = new Date;
		Jour = Today.getDate();
		temp1 = ((Jour < 10) ? "0" : "") ;	
		Mois = (Today.getMonth())+1;
		temp2 = ((Mois < 10) ? ".0" : ".") ;
		Annee = Today.getYear();
	
	var head=document.getElementsByTagName("head")[0].innerHTML; 
	object = document.getElementsByTagName("object")[0]; 
	if (object!=null)
	{content_vlue='<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000"'
	+'codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab" width="690"' 
	+'height="450"  align="middle">'+object.innerHTML+'</object>';}
	
	 var strprint='<?xml version="1.0" encoding="iso-8859-1"?><!DOCTYPE html'
		+'PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"'
		+'"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">'
		+'<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="fr" lang="fr">'
		+ '<head>'+head+'<link href="fileadmin/css/print.css" rel="stylesheet" type="text/css">'
		+'</head>'
		+'<body>' 
		+'<div id="zone-texte-">'
		+'<div id="zone-texte2">'
		+'<div class="module-print">'
		+'<div id="b-logo"><img src="fileadmin/img/imprimer/logo_epamarne.gif" name="logo" width="272" height="111" id="logo"/></div>'
		+'<div id="bandeau1_print"><img src="fileadmin/img/imprimer/image_haut1.jpg" '
		+'width="237" height="111"/><img src="fileadmin/img/imprimer/image_haut2.jpg" '
		+'width="129" height="111"/><img src="fileadmin/img/imprimer/coin_bandeau.gif" '
		+'width="11" height="111"/><br/>'
		+'<img src="fileadmin/img/imprimer/image_bas_bandeau.jpg"/></div>'
		+'<div id="corps-popup">'
		+'<div id="zone-texte-popup">'
		+'<div id=print align="right">Imprimé le '+temp1+Jour+temp2+Mois+"."+String(Annee).substr(2,2)+'<div align=right id="boutonimprimer"><br /><br /><input type="button" class="button2" name="imprimer" id="imprimer" value="Imprimer"  onclick="javascript:print_page()"></div></div>'
 		+content_vlue
		+'</div></div></div><img src="fileadmin/img/imprimer/fond_image_bas.gif" '
		+ 'width="648" height="125"/>'
		+'</div>' 
		+'<br/></br/></body></html>';	
		
	 docprint.document.write(strprint); 
	
	}
}

function print_page()
{
	document.getElementById("imprimer").style.visibility='hidden';
	window.print();
	document.getElementById("imprimer").style.visibility='visible';
}
/****** fin impression *****************/


/**********************************************/
/* script appelé par send_form_mail.php
/*******************************************/
function isnumeric(strString)
   {
   var strValidChars = "0123456789.-";
   var strChar;
   var blnResult = true;

//   if (strString.length == 0) return false;

     for (i = 0; i < strString.length && blnResult == true; i++)
      {
      strChar = strString.charAt(i);
      if (strValidChars.indexOf(strChar) == -1)
         {
         blnResult = false;
         }
      }
   return blnResult;
   }

/****** fin script appelé par send_form_mail.php **************/


/**** functions de contrôle sur formulaire **********************************/
/***************************************************************************/

function verif_isnumeric(a)
{if (!isnumeric(a.value))   {alert("Cette mention n'est pas un nombre!");a.value=a.value.substring(0,a.value.length-1);a.focus();}}

function verif_mail(a){
 if(a.value.indexOf('@') == -1||a.value.indexOf('.') == -1) {
   alert("Ce n'est pas une adresse électronique!");
   a.focus();
   return false;
  }
else
return true;
}

function dolink(ad){
   link = 'mailto:' + ad.replace(/\.\..+t\.\./,"@"); 
   return link;
}

function JSGetSwfVer(i){
	// NS/Opera version >= 3 check for Flash plugin in plugin array
	if (navigator.plugins != null && navigator.plugins.length > 0) {
		if (navigator.plugins["Shockwave Flash 2.0"] || navigator.plugins["Shockwave Flash"]) {
			var swVer2 = navigator.plugins["Shockwave Flash 2.0"] ? " 2.0" : "";
      		var flashDescription = navigator.plugins["Shockwave Flash" + swVer2].description;
			descArray = flashDescription.split(" ");
			tempArrayMajor = descArray[2].split(".");
			versionMajor = tempArrayMajor[0];
			versionMinor = tempArrayMajor[1];
			//alert(flashDescription);
			if ( descArray[3] != "" ) {
				tempArrayMinor = descArray[3].split("r");
			} else {
				tempArrayMinor = descArray[4].split("r");
			}
      		versionRevision = tempArrayMinor[1] > 0 ? tempArrayMinor[1] : 0;
            flashVer = versionMajor + "." + versionMinor + "." + versionRevision;
      	} else {
			flashVer = -1;
		}
	}
	// MSN/WebTV 2.6 supports Flash 4
	else if (navigator.userAgent.toLowerCase().indexOf("webtv/2.6") != -1) flashVer = 4;
	// WebTV 2.5 supports Flash 3
	else if (navigator.userAgent.toLowerCase().indexOf("webtv/2.5") != -1) flashVer = 3;
	// older WebTV supports Flash 2
	else if (navigator.userAgent.toLowerCase().indexOf("webtv") != -1) flashVer = 2;
	// Can't detect in all other cases
	else {
		
		flashVer = -1;
	}
	return flashVer;
} 

function DetectFlashVer(reqMajorVer, reqMinorVer, reqRevision) 
{   
	var isIE  = (navigator.appVersion.indexOf("MSIE") != -1) ? true : false;
	var isWin = (navigator.appVersion.toLowerCase().indexOf("win") != -1) ? true : false;
	var isOpera = (navigator.userAgent.indexOf("Opera") != -1) ? true : false;
    
 	reqVer = parseFloat(reqMajorVer + "." + reqRevision);
   	// loop backwards through the versions until we find the newest version	
	for (i=25;i>0;i--) {	
		if (isIE && isWin && !isOpera) {
			versionStr = VBGetSwfVer(i);
		} else {
			versionStr = JSGetSwfVer(i);		
		}
//	 alert(JSGetSwfVer(i));
		if (versionStr == -1 ) { 
			return false;
		} else if (versionStr != 0) {
			if(isIE && isWin && !isOpera) {
				tempArray         = versionStr.split(" ");
				tempString        = tempArray[1];
				versionArray      = tempString .split(",");				
			} else {
				versionArray      = versionStr.split(".");
			}
			versionMajor      = versionArray[0];
			versionMinor      = versionArray[1];
			versionRevision   = versionArray[2];
			
			versionString     = versionMajor + "." + versionRevision;   // 7.0r24 == 7.24
			versionNum        = parseFloat(versionString);
        	// is the major.revision >= requested major.revision AND the minor version >= requested minor
			if ( (versionMajor > reqMajorVer) && (versionNum >= reqVer) ) {
				return true;
			} else {
				return ((versionNum >= reqVer && versionMinor >= reqMinorVer) ? true : false );	
			}
		}
	}	
}

/**************** fin functions de contrôle sur formulaire **********************************/

function display(myimage) {
 html = "<HTML><HEAD><TITLE>Photo</TITLE>" +
  "</HEAD><BODY LEFTMARGIN=0 " +
  "MARGINWIDTH=0 TOPMARGIN=0 MARGINHEIGHT=0><CENTER>" +
  "<IMG SRC='/" + myimage + "' BORDER=0 NAME=image " +
  "onload='window.resizeTo(document.image.width+60,document.image.height+60)'></CENTER>" +
  "</BODY></HTML>";
 popup=window.open
   ('','image','toolbar=0,location=0,directories=0,menuBar=0,scrollbars=0,resizable=1');
 popup.document.open();
 popup.document.write(html);
 popup.document.focus();
 popup.document.close();
 }

/*************************************************************************/

/***************************ajouter au favoris ****************************/
function ajouterfavoris(){
	if ( window.external ){
		window.external.addfavorite('http://www.epa-marnelavallee.fr', 'Epamarne - Epamarne - Marne La Vallée');
	}else{
		window.sidebar.addPanel('Epamarne - Epamarne - Marne La Vallée','http://www.epa-marnelavallee.fr',''); 
	}
}
/***************************finb ajouter au favoris ***********************/
/*************************** gestion de la hauteur du menu gauche ****************************/
function menugauche(){
//
delta=-50;
hauteurA=0;
hauteurG=document.getElementById("menu-gauche").offsetHeight;
hauteurC=document.getElementById("zone-texte-").offsetHeight;
hauteurT=document.getElementById("zone-texte2").offsetHeight;
if (document.getElementById("actualite2")) {
	hauteurA=document.getElementById("actualite2").offsetHeight;
}
ecart=hauteurC - hauteurT - hauteurA ;
if (hauteurC > (hauteurT + hauteurA)){
	total = hauteurC - delta ;
}else{
	total = hauteurT + hauteurA - delta;
}
if (ecart < 0 ){
	document.getElementById("zone-texte-").style.height=hauteurC - ecart + delta +"px";
}else{
	if (hauteurG > (hauteurT + hauteurA - delta) ){
		document.getElementById("zone-texte-").style.height=hauteurG +"px";
	}else{
		document.getElementById("zone-texte-").style.height=hauteurT + hauteurA - delta +"px";
	}
}

}


var listechamps=new Array(6);
listechamps[0] = "_nom$$T$$Vous devez saisir le nom";
listechamps[1] = "_prenom$$T$$Vous devez saisir le prénom";
listechamps[2] = "_telephonne$$T$$Vous devez saisir le téléphonne";
listechamps[3] = "_email$$T$$Vous devez saisir le courriel";
listechamps[4] = "_sujet$$T$$Vous devez sélectionner l'objet du courriel";
listechamps[5] = "_message$$T$$Vous devez saisir message";

var listechampsUS=new Array(6);
listechampsUS[0] = "_nom$$T$$Last name required";
listechampsUS[1] = "_prenom$$T$$First name required";
listechampsUS[2] = "_telephonne$$T$$Phone number required";
listechampsUS[3] = "_email$$T$$E-mail  required";
listechampsUS[4] = "_sujet$$T$$Select subject category ";
listechampsUS[5] = "_message$$T$$Message required";


function VerifFormContact(leform){
	monform = document.getElementById(leform);
	langue= document.getElementById("langue");
	if(langue=="US"){
			ValiderFormulaire(monform, listechampsUS);
		}else{
			ValiderFormulaire(monform, listechamps);
	}
}

function ValiderFormulaire(leform, leschamps){
mesg ="";
for (var i=0; i < leschamps.length; ++i){
	mesg =  mesg + testervaliditechamps(leschamps[i]) ;
}
if (mesg=="") {
	leform.submit();
}else if (mesg.indexOf("KO") > -1) {
	//return "";
}else{
	alert(mesg);
}
}

function testervaliditechamps(valeur) {
temp = valeur.split("$$");
if (temp[1] =="T" ) {
	if (document.getElementById(temp[0]).value=="" ){
		return temp[2]+"\n";
	}
	return "";
}else if(temp[1] !="T"){
	return TesterContenuChamps(temp);
	return "";
}
return "";
}
function TesterContenuChamps(letableau){
lechamp= document.getElementById(letableau[0]);
lavaleur= document.getElementById(letableau[0]).value;
if (lavaleur!=""){
	if (eval("Champ"+letableau[1]+"(letableau)") ){
		return "";
	}else{
		if (letableau[2]!="KO"){
			alert(letableau[2]);
			return "KO";
		}else{
			return "KO";
		}
	}
}else{
	return "";
}
return "";
}

/*************************** fin gestion de la hauteur du menu gauche ****************************/
// -->
/*]]>*/