var isIE = (navigator.appName.indexOf("Microsoft") != -1) ? true : false;	// Detecting Explorer

// Scripts for images		document[changeImages.arguments[i]].src = changeImages.arguments[i+1];	}	}}
function MM_swapImgRestore() {   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() { 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_findObj(n, d) {   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); return x;}
function MM_swapImage() {   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];}}

//-->

var winId = 0;
function zoom(image,w,h,titre){ // 2.1 - Si [image] contient ".html", ouverture simple (peut servir pour pop-ups)
		// Creation d'un pop-up centre pour zoom d'images
		var titre;
		if(!titre) titre = "Agrandissement du plan";
		winId++;
	    if (isIE) winLeft=( ((document.body.clientWidth - w) / 2) + (isNaN(window.screenLeft) ? 10 : window.screenLeft) - 3);
			else winLeft=( (((window.innerWidth - 20) - w) / 2) + window.screenX + 3);
		if (isIE) winTop=( ((document.body.clientHeight - h) / 2) + (isNaN(window.screenTop) ? 10 : window.screenTop) - 13);
			else winTop=( ((window.innerHeight - h) / 2) + window.screenY + (window.outerHeight - window.innerHeight - 40) - 8);

		if(image.indexOf(".html") != -1) {
			z = window.open(image,"zoom"+winId,"width=" + (w > 750 ? 750 : w) + ",height=" + (h > 550 ? 550 : h) + ",location=0,toolbar=0,directories=0,status=0,menubar=0,scrollbars=" + ((h > 550 || w > 750) ? 1 : 0) + ", resizable=0,top=" + winTop + ",left=" + winLeft);
		} else {
			z=window.open("","zoom"+winId,"width=" + (w > 750 ? 750 : w) + ",height=" + (h > 550 ? 550 : h) + ",location=0,toolbar=0,directories=0,status=0,menubar=0,scrollbars=" + ((h > 550 || w > 760) ? 1 : 0) + ", resizable=0,top=" + winTop + ",left=" + winLeft);

			d=z.document;

			d.write('<html><head><title>' + titre + '</title></head>');
			d.write('<body marginheight=0 marginwidth=0 leftmargin=0 rightmargin=0 bottommargin=0 topmargin=0 bgcolor="#596773">');
			d.write('<a href="javascript:self.close();"><img src="images/' + image + '" width=' + w + ' height=' + h + ' border="0" alt="' + titre + ' \n\nCliquez pour fermer la fen&ecirc;tre \nPour enregistrer l\'image, avec le bouton droit, \nCliquez sur \'Enregistrer l\'image sous...\'"></a>');
			d.write('</body></html>');
			d.close();
		}
}