function MM_preloadImages() { //v2.0
  if (document.images) {
    var imgFiles = MM_preloadImages.arguments;
    if (document.preloadArray==null) document.preloadArray = new Array();
    var i = document.preloadArray.length;
    with (document) for (var j=0; j<imgFiles.length; j++) if (imgFiles[j].charAt(0)!="#"){
      preloadArray[i] = new Image;
      preloadArray[i++].src = imgFiles[j];
  } }
}
//----------------------------------------------------------------------------------------
function MM_swapImgRestore() { //v2.0
  if (document.MM_swapImgData != null)
    for (var i=0; i<(document.MM_swapImgData.length-1); i+=2)
      document.MM_swapImgData[i].src = document.MM_swapImgData[i+1];
}
//----------------------------------------------------------------------------------------
function MM_swapImage() { //v2.0
  var i,j=0,objStr,obj,swapArray=new Array,oldArray=document.MM_swapImgData;
  for (i=0; i < (MM_swapImage.arguments.length-2); i+=3) {
    objStr = MM_swapImage.arguments[(navigator.appName == 'Netscape')?i:i+1];
    if ((objStr.indexOf('document.layers[')==0 && document.layers==null) ||
        (objStr.indexOf('document.all[')   ==0 && document.all   ==null))
      objStr = 'document'+objStr.substring(objStr.lastIndexOf('.'),objStr.length);
    obj = eval(objStr);
    if (obj != null) {
      swapArray[j++] = obj;
      swapArray[j++] = (oldArray==null || oldArray[j-1]!=obj)?obj.src:oldArray[j];
      obj.src = MM_swapImage.arguments[i+2];
  } }
  document.MM_swapImgData = swapArray; //used for restore
}

//----------------------------------------------------------------------------------------
function Ouvrir(page,Larg,haut) { 
La_page=window.open(page,'p','screenX=50,left=50,screenY=50,top=50,width='+ Larg + ',height=' + haut + ',fullscreen=0,location=0,menubar=0,resizable=0,scrollbars=0,status=0,toolbar=0');

} 
function Fermer() { 
La_page.close() 
} 


//----------------------------------------------------------------------------------------
function PopupImage(page,img) { 
FixeCookie ("imgsrc", img , null,"/");
//var image01 =new image
//image01.src=imagesrce 

La_page=window.open(page,'p','screenX=50,left=50,screenY=50,top=50,width=10,height=10,fullscreen=0,location=0,menubar=0,resizable=0,scrollbars=0,status=0,toolbar=0');

} 

//----------------------------------------------------------------------------------------
function PopupPage(page) { 
var idpage = Math.random();
idpage *= 100;
idpage = Math.round(idpage);

La_page(idpage)=window.open(page,'p','screenX=50,left=50,screenY=50,top=50,width=10,height=10,fullscreen=0,location=0,menubar=0,resizable=0,scrollbars=0,status=0,toolbar=0');

} 

//----------------------------------------------------------------------------------------
function PopupImage2(img) {
	titre="Les Girard du Boucou Chateauneuf du Pape";
	w=open("",'image','width=10,height=10,toolbar=no,scrollbars=no,resizable=no,status=no,location=0');	
	w.document.write("<HTML><HEAD><TITLE>"+titre+"</TITLE>");
	w.document.write("<SCRIPT language=javascript>function clicie() { if ((event.button==2)||(event.button==3)) { alert('Jacques.Girard (c)2002.');}</"+"SCRIPT>");


	w.document.write("</HEAD>");
	w.document.write("<SCRIPT language=javascript>function checksize()  { if (document.images[0].complete) {  window.resizeTo(document.images[0].width+12,document.images[0].height+30); window.focus();} else { setTimeout('checksize()',20) } }</"+"SCRIPT>");
	w.document.write("<BODY onload='checksize()' leftMargin=0 topMargin=0 marginwidth=0 marginheight=0>");
	w.document.write("<IMG src='"+img+"' border=0>");
	w.document.write("<p ><font color='#996633' size=3 ><b><i><font face='Verdana'>Charge</font>...</i></b></font></p> ");
	w.document.write("</BODY></HTML>");
	w.document.close();
}

//----------------------------------------------------------------------------------------
// Script réalisé par http://www.toutjavascript.com

var TabAlpha=new Array();
TabAlpha.length=5;		// 5 images alpha A MODIFIER SI PLUS D'IMAGES

for (var alphaI=0;alphaI<TabAlpha.length;alphaI++) {
	TabAlpha[alphaI]=-1;
}

function ModifAlpha(no,alpha){
	if (document.images["img"+no]) {
		if (document.images["img"+no].filters) {
			TabAlpha[no]=alpha;
			if (tjstimer==0) {setTimeout("tjstimerAlpha()",30)}
		}
	}
}

var tjstimer=0;

function tjstimerAlpha() {
	var opacity=0;
	for (var alphaI=0;alphaI<TabAlpha.length;alphaI++) {
		if (TabAlpha[alphaI]!=-1) {
			opacity =TabAlpha[alphaI] - document.images["img"+alphaI].filters.alpha.opacity;
			if (opacity!=0) {
				tjstimer=1;
				document.images["img"+alphaI].filters.alpha.opacity+=Math.abs(opacity)/opacity * 5;		
			} else {
				TabAlpha[alphaI]=-1
			}
		}
	}
	if (tjstimer==1) {setTimeout("tjstimerAlpha()",30);} else {tjstimer=0}
}






//----------------------------------------------------------------------------------------
var bookmarkurl
var bookmarktitle
function addbookmark(bookmarkurl,bookmarktitle){
if (document.all)
window.external.AddFavorite(bookmarkurl,bookmarktitle)
}

//----------------------------------------------------------------------------------------
var valu
var pagehtml
function change_frame(valu,pagehtml) {

FixeCookie ("TxtHaut", valu , null,"/");
parent.framehaut.location.href=pagehtml;
}



//----------------------------------------------------------------------------------------
	<!--

		//  Function DateExpiration
		//  fixe la date d'expiration
		function DateExpiration (DateExp) {
			var aujourdhui = new Date(0);
			var aujourdhuidate = aujourdhui.getTime();
			if (aujourdhuidate > 0)
				DateExp.setTime (DateExp.getTime() - aujourdhuidate);
		}
//----------------------------------------------------------------------------------------
		//  Function FixeCookie
		//  pour créer ou modifier un cookie
		function FixeCookie (nom,valeur,expire,path,domaine,securise) {
			document.cookie = nom + "=" + escape (valeur) + ((expire) ? "; expires=" + expire.toGMTString() : "") + ((path) ? "; path=" + path : "") + ((domaine) ? "; domain=" + domaine : "") + ((securise) ? "; secure" : "");
		}
//----------------------------------------------------------------------------------------
		//  Function SupprCookie
		//  Supprime un Cookie
		function SupprCookie (nom,path,domaine) {
			if (GetValeurCookie(nom)) {
				document.cookie = nom + "=" + ((path) ? "; path=" + path : "") + ((domaine) ? "; domain=" + domaine : "") + "; expires=Thu, 01-Jan-70 00:00:01 GMT";
			}
		}
//----------------------------------------------------------------------------------------
		//  Function ValeurCookie
		//  Utiliser par GetValeurCookie
		function ValeurCookie (Pos) {
			var endstr = document.cookie.indexOf (";", Pos);
			if (endstr == -1)
				endstr = document.cookie.length;
			return unescape(document.cookie.substring(Pos, endstr));
		}
//----------------------------------------------------------------------------------------
		//  Function GetValeurCookie
		//  pour récupérer la valeur d'un cookie
		function GetValeurCookie (nom) {
			var cookielength = document.cookie.length;
			var arg = nom + "=";
			var arglength = arg.length;
			var i = 0;
			while (i < cookielength) {
			var j = i + arglength;
			if (document.cookie.substring(i, j) == arg)
				return ValeurCookie (j);
				i = document.cookie.indexOf(" ", i) + 1;
				if (i == 0) break; 
			}
			return null;
		}
//--------------------------------------------------------------------------------------


// Fonctions de préload
function load() {
	if (document.images) {
		this.length=load.arguments.length;
		for (var i=0;i<this.length;i++) {
			this[i+1]=new Image();
			this[i+1].src=load.arguments[i];
		}
	}
}
// Cette fonction charge dans le cache toutes les images passées en paramètre
function preload(chaineImage) {

	var temp=new load(chaineImage)
}

//----------------------------------------------------------------------------------------

function clicie() {

	// Fonction de détection pour Internet Explorer

	if ((event.button==2)||(event.button==3)) {
		alert("Jacques.Girard (c)2002.");
	}
}


//----------------------------------------------------------------------------------------
function clicns(e){
	// Fonction pour Netscape
	if(e.which==3){
		alert("Jacques.Girard (c)2002.");
		return false;
	}
}

//----------------------------------------------------------------------------------------
if (document.all) {document.onmousedown=clicie;}
if (document.layers) {document.captureEvents(Event.MOUSEDOWN); document.onmousedown = clicns;}
if (window.sidebar) {document.captureEvents(Event.MOUSEDOWN); document.onmousedown = clicns;}





//----------------------------------------------------------------------------------------
// texte contient le message à afficher par défaut
var Defauttexte="www.mas-du-boucou.com";

top.defaultStatus=Defauttexte;

function msg(txt) {
	top.status=txt;
}


//----------------------------------------------------------------------------------------
// Fonction roolover permet de changer l'image sur le passage
function rollover_tjs(nom,src) {
        // nom est le nom de l'image
        //        Dans cet exemple, nom = lesmiley
        // src est l'adresse du fichier d'image
        document.images[nom].src=src;
}

//---------------------------------------------------------------------------
//      fonction makeStatic2 nomoj est l' ID de la ballise DIV, fromtop le top d'affichage du div
var fromtop=-20
function makeStatic2(nomObj,fromtop) {
if (document.all)        {         nomObj.style.pixelTop=document.body.scrollTop+ fromtop        }
else         {        eval(document.nomObj.top=eval(window.pageYOffset+fromtop));        }
//setTimeout("makeStatic2(object1,100)",0);
}

