

//<!--
//window.onerror=null;		// ALLUMER AVANT LA MISE EN ONDES

//var msgWindow = null;

// =============================================================
// OPENW =======================================================
// =============================================================
function DetectCSS(ou)	{

css_IEm = "mind_mac_ex.css";
css_IEp = "mind_pc_ex.css";
css_NSm4 = "mind_mac_ns4.css";
css_NSm5 = "mind_mac_ns5.css";
css_NSp4 = "mind_pc_ns4.css";
css_NSp5 = "mind_pc_ns5.css";


// DetectPlateform =====================================
var isMAC	=	(navigator.userAgent.indexOf("Mac") != -1);
var isLin	=	(navigator.userAgent.indexOf("Linux")!=-1);
var isPC	=	(navigator.userAgent.indexOf("Win") != -1);

// DetectFureteur ======================================
var isNS4	=	(navigator.appName == "Netscape" && parseInt(navigator.appVersion) < 5);
var isNS5	=	(navigator.appName == "Netscape" && parseInt(navigator.appVersion) >= 5);
var isIE5	=	(navigator.appName == "Microsoft Internet Explorer" && parseInt(navigator.appVersion) >= 4);

if ( isMAC == true) {
	if ( isNS4 == true)	{	document.write("<link rel='stylesheet' href='" + ou + "/" + css_NSm4 + "' type='text/css'>");	};
	if ( isNS5 == true)	{	document.write("<link rel='stylesheet' href='" + ou + "/" + css_NSm5  + "' type='text/css'>");	};
	if ( isIE5 == true)	{	document.write("<link rel='stylesheet' href='" + ou + "/" + css_IEm  + "' type='text/css'>");	};
	};
	
if ( isPC  == true)	{
	if ( isNS4 == true)	{	document.write("<link rel='stylesheet' href='" + ou + "/" + css_NSp4 + "' type='text/css'>");	};
	if ( isIE5 == true)	{	document.write("<link rel='stylesheet' href='" + ou + "/" + css_IEp  + "' type='text/css'>");	};
	if ( isNS5 == true)	{	document.write("<link rel='stylesheet' href='" + ou + "/" + css_NSp5  + "' type='text/css'>");	};
	};
}

function openW(image,quelle,nom,texte,large,haut,plus,flash,ou,mov) {

var haut; var plus; var large;
var hauteur = (haut + plus);
var largeur = large;

// DetectPlateform ========================================
var isMAC	=	(navigator.userAgent.indexOf("Mac") != -1);
var isLin	=	(navigator.userAgent.indexOf("Linux")!=-1);
var isPC	=	(navigator.userAgent.indexOf("Win") != -1);
// DetectFureteur =========================================
var isNS4	=	(navigator.appName == "Netscape" && parseInt(navigator.appVersion) == 4);
var isNS6	=	(navigator.appName == "Netscape" && parseInt(navigator.appVersion) >= 5);
var isIE5	=	(navigator.appName == "Microsoft Internet Explorer" && parseInt(navigator.appVersion) >= 4);
// DetectEcran =========================================
var cGauch	=	((screen.width/2)-(large/2+10));
var cHaut	=	((screen.height/2)-(hauteur/2+10));
// Detect ============================================ie5MAC
var	lIE5m	=	largeur;
var	hIE5m	=	hauteur;
// Detect ============================================ns4MAC
var	lNS4m	=	largeur;
var	hNS4m	=	hauteur-1;
// Detect ============================================ns6MAC
var	lNS6m	=	largeur;
var	hNS6m	=	hauteur+1;
// Detect =============================================ie5PC
var	lIE5p	=	largeur+10;
var	hIE5p	=	hauteur+29;
// Detect =============================================ns4PC
var	lNS4p	=	largeur;
var	hNS4p	=	hauteur;
// Detect =============================================ns6PC
var	lNS6p	=	largeur+6;
var	hNS6p	=	hauteur+26;
// Detect =============================================LINUX
var	lLin	=	largeur-100;
var	hLin	=	hauteur;

// Construction de taille ==================================
	if ( isMAC == true) {	if ( isNS4 == true)	{	h=hNS4m; l=lNS4m;	};};
	if ( isMAC == true) {	if ( isNS6 == true)	{	h=hNS6m; l=lNS6m;	};};
	if ( isMAC == true) {	if ( isIE5 == true)	{	h=hIE5m; l=lIE5m;	};};
	if ( isPC  == true)	{	if ( isNS4 == true)	{	h=hNS4p; l=lNS4p;	};};
	if ( isPC  == true)	{	if ( isNS6 == true)	{	h=hNS6p; l=lNS6p;	};};
	if ( isPC  == true)	{	if ( isIE5 == true)	{	h=hIE5p; l=lIE5p;	};};


// Ouverture de la fenetre =================================
	msgWindow = window.open("" + quelle + "", "" + nom + "", "left=" + cGauch + ",top=" + cHaut + ",location=no,directories=no,status=no,titlebar=yes,menubar=no,scrollbars=yes,resize=yes,height=" + h + ",width=" + l + "");
//	if(isNS4) alert('NS4');
//	if(isNS6) alert('NS6');
//	if(msgWindow && !msgWindow.closed) alert('msgWindow');

//	if(msgWindow && !msgWindow.closed) //msgWindow.close();
//	Controle de difference de resizeTo entre NS et IE
	if (parseInt(navigator.appVersion)>3) {
		if (navigator.appName=="Netscape") {
			msgWindow.outerWidth=l;
			msgWindow.outerHeight=h;
			//msgWindow.window.resizeTo(l, h);
			//alert('Netscape');
		}
		else {
			msgWindow.resizeTo(l, h);
			//alert('Explorer');
		}
	}
	//alert(l,h);
	msgWindow.moveTo(cGauch, cHaut);
	msgWindow.focus();


if (quelle=='none.html') {
	msgWindow = window.open("", "" + nom + "", "left=" + cGauch + ",top=" + cHaut + ",titlebar=no,menubar=no,scrollbars=yes,height=" + h + ",width=" + l + "");
	msgWindow.document.open();
	msgWindow.focus();
	msgWindow.document.write("<html><head><title>[ ~tM~ ]</title></head>\n");
	msgWindow.document.write("<meta http-equiv=Content-Type content=text/html; charset=iso-8859-1>\n");
	msgWindow.document.write("<body bgcolor=#cccccc link=#999999 vlink=#999999 alink=#000000 topmargin=0 leftmargin=0 rightmargin=0 marginwidth=0 marginheight=0>\n");	}


// images =================================================
if (image!='image') {
	msgWindow.document.write("<a HREF=javascript:window.close()><img SRC=images/" + image + " height=" + haut + " width=" + large + " border=0></a><br>\n");
	}

// Texte ==================================================
if (texte!='texte') {
	msgWindow.document.write("<table CELLPADDING=0 CELLSPACING=10 width=100% height="+plus+" BORDER=0><tr><td align=center valign=middle>");
	msgWindow.document.write("<font face=helvetica color=#666666 size=1>"+texte+"</font>");
	msgWindow.document.write("</td></tr></table>");
	}

//countdown ===============================================
if (flash=='flash_oui') {
	msgWindow.document.write("<object classid='clsid:D27CDB6E-AE6D-11cf-96B8-444553540000' codebase='http://active.macromedia.com/flash2/cabs/swflash.cab#version=4,0,0,0' ID=flash_intro WIDTH=240 HEIGHT=196>\n");
	msgWindow.document.write("<param NAME=movie VALUE='../images/count_video.swf'><param NAME=loop VALUE=false>\n");
	msgWindow.document.write("<param NAME=menu VALUE=false><param NAME=quality VALUE=high>\n");
	msgWindow.document.write("<param NAME=scale VALUE=noborder><param NAME=bgcolor VALUE=#CCCCCC>\n");
	msgWindow.document.write("<embed src='../images/count_video.swf' loop=false menu=false quality=high scale=noborder bgcolor=#CCCCCC WIDTH=240 HEIGHT=196 TYPE='application/x-shockwave-flash' PLUGINSPAGE='http://www.macromedia.com/shockwave/download/index.cgi?P1_Prod_Version=ShockwaveFlash'>\n");
	msgWindow.document.write("</embed>\n</object>\n");
	msgWindow.document.write("<script>timerID=setTimeout ('redirect()',5000);function redirect() {	document.location='" + ou + "'	}</script>\n");
	}
if (flash=='flash_non') {
	msgWindow.document.write("<script>timerID=setTimeout ('redirect()',0);function redirect() {	document.location='" + ou + "'	}</script>\n");
	}
if (flash=='flash_image') {}



// Movie ==================================================
if (ou=='movie_oui') {
	msgWindow.document.write('<table CELLPADDING=0 CELLSPACING=0 width="'+large+'" height="'+haut+'" BORDER=0>\n<tr><td align=center valign=middle>\n');

//	if (navigator.mimeTypes && navigator.mimeTypes["video/quicktime"])	{

		msgWindow.document.write('<embed src='+mov+' width='+large+' height='+hauteur+' autoplay=true loop=false controller=true pluginspage=http://www.apple.com/quicktime/>\n');
		msgWindow.document.write('</embed>\n');
//	}
//else {
//		msgWindow.document.write('<TABLE cellspacing=0 cellpadding=0 border=0 width=100% height=100%><TR><TD align=center valign=middle>');
//		msgWindow.document.write('<IMG SRC="images/noQT.jpg" WIDTH="240" HEIGHT="180"><br>');
//		msgWindow.document.write('<FONT face="Helvetica" size=1 color="#cccccc">Pour voir cet extrait, il vous faut <A HREF="http://www.apple.com/quicktime/download/" target="_new">Quicktime4.0</A>');
//	msgWindow.document.write('</TD></TR></TABLE>\n');	}

	msgWindow.document.write('</td></tr></table>\n');
	}
if (ou!='movie_oui') {}

// Fermeture =============================================
if (quelle=='../none.html') {
	msgWindow.document.write("</body></html>");
	msgWindow.document.close();	}
	}


// Wmove =============================================
function Wmove(haut,large) {
	if (parseInt(navigator.appVersion) >= 4)
		window.moveTo((screen.width/2)-(large/2+10),(screen.height/2)-(haut/2+20));
	}
	
	
// =========================================================
// FIN DE OPENW ============================================
// =========================================================



// NextPrev ================================================
function goPrev(last,prevdir,currentdir) {
	currLoc = parent._Nav2.document.title
	currOffset = parseInt(currLoc.substring(5,6))
	if (currOffset > 1) {	currOffset = --currOffset
	parent._Nav2.location.href = ""+currentdir+"index" + currOffset + ".html"
	} else {
	top._contenu.location.href = ""+prevdir+"index.html"
	}	}

function goNext(last,currentdir,nextdir) {
	currLoc = parent._Nav2.document.title
	currOffset = parseInt(currLoc.substring(5,6))
	if (currOffset <= last-1) {	currOffset = ++currOffset
	parent._Nav2.location.href = ""+currentdir+"index"+currOffset+".html"
	} else {
//	alert(currOffset)
	top._contenu.location.href = ""+nextdir+"index.html"
	}	}





//  Swap et Preload ========================================
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_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_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_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];}
}

function MM_displayStatusMsg(msgStr) { //v1.0
  status=msgStr;
  document.MM_returnValue = true;
}

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 Is(){
var agent = navigator.userAgent.toLowerCase();
this.major = parseInt(navigator.appVersion);
this.minor = parseFloat(navigator.appVersion);
this.mac = (navigator.userAgent.indexOf("Mac") != -1);
this.pc = (navigator.userAgent.indexOf("Win") != -1);
this.ns = ((agent.indexOf('mozilla')!= -1)&&((agent.indexOf('spoofer')== -1)&&(agent.indexOf('compatible')== -1)));
this.ns4 = (this.ns && (this.major == 4));
this.ns6 = (this.ns && (this.major >= 5));
this.ie = (agent.indexOf("msie")!= -1);
this.ie4 = (this.ie && (this.major == 4)&&(agent.indexOf("msie 5.")== -1));
this.ie5 = (this.ie && (this.major >= 4)&&(agent.indexOf("msie 5.")!=-1));
}














/*
Parse Get
*/

function createRequestObject() {
  
  FORM_DATA = new Object();
    // The Object ("Array") where our data will be stored.
  
  separator = ',';
    // The token used to separate data from multi-select inputs
  
  query = '' + this.location;
    // Get the current URL so we can parse out the data.
    // Adding a null-string '' forces an implicit type cast
    // from property to string, for NS2 compatibility.
    
  query = query.substring((query.indexOf('?')) + 1);
    // Keep everything after the question mark '?'.
  
  if (query.length < 1) { return false; }  // Perhaps we got some bad data?
  
  keypairs = new Object();
  numKP = 1;
    // Local vars used to store and keep track of name/value pairs
    // as we parse them back into a usable form.
    
  while (query.indexOf('&') > -1) {
    keypairs[numKP] = query.substring(0,query.indexOf('&'));
    query = query.substring((query.indexOf('&')) + 1);
    numKP++;
      // Split the query string at each '&', storing the left-hand side
      // of the split in a new keypairs[] holder, and chopping the query
      // so that it gets the value of the right-hand string.
  }

  keypairs[numKP] = query;
    // Store what's left in the query string as the final keypairs[] data.
  
  for (i in keypairs) {
    keyName = keypairs[i].substring(0,keypairs[i].indexOf('='));
      // Left of '=' is name.
    keyValue = keypairs[i].substring((keypairs[i].indexOf('=')) + 1);
      // Right of '=' is value.
    while (keyValue.indexOf('+') > -1) {
      keyValue = keyValue.substring(0,keyValue.indexOf('+')) + ' ' + keyValue.substring(keyValue.indexOf('+') + 1);
        // Replace each '+' in data string with a space.
    }
    
    keyValue = unescape(keyValue);
      // Unescape non-alphanumerics
      
    if (FORM_DATA[keyName]) {
      FORM_DATA[keyName] = FORM_DATA[keyName] + separator + keyValue;
        // Object already exists, it is probably a multi-select input,
        // and we need to generate a separator-delimited string
        // by appending to what we already have stored.
    } else {
      FORM_DATA[keyName] = keyValue;
        // Normal case: name gets value.
    }
  }

  return FORM_DATA;
}

FORM_DATA = createRequestObject();
  // This is the array/object containing the GET data.
  // Retrieve information with 'FORM_DATA [ key ] = value'.

function goSearch()		{	window.document.form2.submit();	}

function Setcache ()	{	setTimeout('cacheForm()',600000);	}
function cacheForm ()	{	MM_showHideLayers('L1','','hide','L2','','hide','L3','','hide','L4','','hide');	}

function redirectframe() {
  if (parent.location.href == self.location.href){
     var pathtop = top.location.pathname;
     var patharray = pathtop.split('/');
     var language = patharray[1];
     var section = patharray[2];
     var file = patharray[3];
     window.location.href = '/en/'+section+'/frame.html?'+file
  }
}


var popwin = null;
function MM_openBrWindow(popupURL,winName,features) {
  var args = features;
  if(popwin && !popwin.closed) popwin.close();
  popwin = window.open(popupURL, '', args);
}


//-->
