if (!document.all) {
  if(typeof HTMLElement!="undefined"){
    HTMLElement.prototype.innerText = function() {
      var tmp = this.innerHTML.replace(/<br>/gi,"\n");
      return tmp.replace(/<[^>]+>/g,"");
    }
  }
}

document.cookie="check=test;"
if (document.cookie.indexOf('test')==-1) {
  alert("La fonction \"cookie\" a été désactivée sur votre ordinateur.\nCette fonction est nécessaire au bon fonctionnement du site\nSi vous utiliser Internet explorer, vous pouvez la réactiver en cliquant sur \"par défaut\" puis OK dans le menu\nOutils / Options Internet / Confidentialité");
}
if (!document.getElementById) {
  alert("Votre navigateur est trop ancien pour pouvoir naviguer sur le site.\nVous pouvez télécharger gratuitement une mise à partir du site du site http://www.getfirefox.com ou http://www.microsoft.fr");
}

/**
  * envoi d'un ctrl I
**/
document.onkeydown = function (e) {
  ev = (document.all)?event:e;
  if (ev.keyCode!=73 || !ev.ctrlKey) return;
  var txt=(document.all)?document.selection.createRange().text:window.getSelection().toString();
  var description = escape(deleteAccents(" - Adresse de la page:\n"+document.URL+"\n\n - Texte d'origine:\n"+txt+"\n\n - Commentaires:\n"));
  //window.open("/commentaire.php5?url="+escape(document.URL)+"&t1="+escape(txt),'commentaire');
  window.open("http://info/bug_tracker/?action=taskForm&rc_service=2&admin=0&description="+description,'commentaire');
  return false;
}

/**
* chargements des scripts
 * @param  listJs liste des scripts à charger
  * @param  execFct fction à exécuter qd tous les scripts sont chargés
  * @param  status 0|1 appelé au chgment de la page ou non
 */
function loadScripts (listJs,execFct,status) {
  //status 0 call when page loaded 1 call directly
  var isLoaded = new Array();
  var isLoading = false;
  var f = function () {init(listJs);};
  init = function() {checkQueue();}

  var loadFile = function (url) {

    var e;
    if (url.lastIndexOf('.css')>0){
      e=document.createElement('LINK');
      e.rel='stylesheet';
      e.type='text/css';
    }else{
      e=document.createElement('script');
      e.setAttribute('language','javascript');
      e.setAttribute('type','text/javascript');
      e.setAttribute('src',url);
      document.getElementsByTagName("head")[0].appendChild(e);
    };

    if (e.tagName=='LINK'){
      if (document.all) e.onload=checkLoad;
      else checkQueue();
      e.href=url;
    }else{
      e.src=url;
      if(/WebKit|Khtml/i.test(navigator.userAgent)) {
        checkQueue();
      }
       e.onload=e.onreadystatechange=checkLoad;
    };
    document.getElementsByTagName("head")[0].appendChild(e);
  }

  var checkQueue=function(){
    if (listJs.length>0){
      isLoading=true;
      var A=listJs[0];
      var B=new Array();
      for (i=1;i<listJs.length;i++) B[i-1]=listJs[i];
      listJs=B;
      loadFile(A);
    }
    else {
      isLoading=false;
      //hack pour safari car ne gère pas l'onload
      execFct();
    }
  };
  var checkLoad = function(){if (this.tagName=='LINK'||!this.readyState||this.readyState=='loaded') checkQueue();}

  if (!status) {
    if (document.all) window.attachEvent("onload",function() {f();});
    else window.addEventListener("load",function () {f();},true);
  }
  else checkQueue();
}

function JSdecrypt(c) {
	var r = new String;
	for (var i=0;i<c.length;i+=2) {
		r += String.fromCharCode(((isNaN(c.charAt(i))?c.charCodeAt(i)-87:parseInt(c.charAt(i),10))*16+(isNaN(c.charAt(i+1))?c.charCodeAt(i+1)-87:parseInt(c.charAt(i+1),10)))-2-(i/2)%3);
	}
	return r;
}

/**
* gère les appels synchrone asynchrone
 * @param  url  du script appelé
  * @param  request chaine de valeur envoyé à ce script
  * @param  callback fonction appelé en retour (pour asynchrone)
 */
function execHttpRequest(url, request, callback) {
  //fction httprequest
  var httpRequest = null;
  var async = (arguments.length==3)?true:false;
  if (window.XMLHttpRequest)
    httpRequest = new XMLHttpRequest();
  else if (window.ActiveXObject) {
    try { httpRequest = new ActiveXObject("Msxml2.XMLHTTP");
    } catch (e) {
       try { httpRequest = new ActiveXObject("Microsoft.XMLHTTP");
       } catch (e) {}
    }
  }
  else {
    alert ("Votre navigateur ne supporte pas l'objet XMLHTTP.");
    return false;
  }
  if (async) httpRequest.open('POST', url, true);
  else httpRequest.open('POST', url, false);
   httpRequest.setRequestHeader("Content-type","application/x-www-form-urlencoded");
//   if (httpRequest.overrideMimeType) httpRequest.setRequestHeader("Connection", "close");
  if (async) {
     var f = function() {
     // readyState
     // 0 (uninitialized)  non initialisé
     // 1 (loading)  début du transfert des données
     // 2 (loaded)  données transférées
     // 3 (interactive)  les données reçues sont accessibles en partie
     // 4 (complete)  les données sont complètement accessibles
     if (httpRequest.readyState==4) {
       try {
         //alert(httpRequest.responseText);
       if (httpRequest.status==200) callback(httpRequest.responseText,httpRequest.status);
       else alert (httpRequest.status+"erreur lors du chargement de la page")
       } catch (ex) {alert ("problème de connexion au serveur !");}
       }
    }
    httpRequest.onreadystatechange = f;
  }
  httpRequest.send(request);
  if (!async) {
    if (httpRequest.readyState==4) {
     try {
       if (httpRequest.status==200)  return httpRequest.responseText;
       else alert (httpRequest.status);
     }
     catch (ex) {
       //alert (ex.message);
     alert ("problème de connexion au serveur !");
     }
   }
 }
}

/**
* ajoute un nouveau style ds 1 document
 * @param  insideDocument document ds lequel insérer le style
  * @param  name nom du style
  * @param  style contenu du style
 */
function addStyle(insideDocument,name,style) {
  //add a style in the first stylesheet
  if (document.all) insideDocument.styleSheets[0].addRule(name,style);
  else insideDocument.styleSheets[0].insertRule (name+'{'+style+'}',insideDocument.styleSheets[0].cssRules.length);
}

/**
* suppression d'accent sur 1 chaine
 * @param  chaine
  * @return chaine formatée
 */
function deleteAccents (chaine) {
  chaine = chaine.replace(/[àâäåãáæ]/gi,"a");
  chaine = chaine.replace(/[éèêë]/gi,"e");
  chaine = chaine.replace(/[ïîìí]/gi,"i");
  chaine = chaine.replace(/[öôóòõø]/gi,"o");
  chaine = chaine.replace(/[ùûüú]/gi,"u");
  chaine = chaine.replace(/[ç]/gi,"c");
  chaine = chaine.replace(/[ÿ]/gi,"y");
  chaine = chaine.replace(/[ñ]/gi,"n");
  return chaine;
}

/**
* calcul de la position d'un élément
 * @param  obj
 * @return  coord objet coord.x coord.y coord.w coord.h
 */
function coordZone (obj) {
  var coord = new Object();
  coord.x=0;
  coord.y=0;
  coord.w=obj.offsetWidth;
  coord.h=obj.offsetHeight;
  do {
    coord.x+=obj.offsetLeft;
    coord.y+=obj.offsetTop;
    obj=obj.offsetParent;
  } while(obj);
  return coord;
}

/**
* calcul de la position d'un élément, prend en compte le bug des éléments gérant l'overflow
 * @param  obj
 * @return coord objet coord.x coord.y coord.w coord.h
 */
function coordZoneOverflow(obj) {
  //pour IE s'arrete au div qui a l'overflow pour calculer la position du bloc
  var coord = new Object();
  var initObj = obj;
  coord.x=0;
  coord.y=0;
  coord.w=obj.offsetWidth;
  coord.h=obj.offsetHeight;
  coord.scrollH=0;
  if (document.all) {
    try {
      do {
        coord.x+=obj.offsetLeft;
        coord.y+=obj.offsetTop;
        obj=obj.offsetParent;
        if (obj.style.overflow) {
          coord.scrollH=obj.scrollTop;
          coord.w-=obj.scrollLeft;
        }
      } while(obj && !obj.style.overflow && obj.tagName!="BODY");
    }
    catch (e) {}
  }
  else {
    do {
      coord.x+=obj.offsetLeft;
      coord.y+=obj.offsetTop;
      obj=obj.offsetParent;
    } while(obj);
    while (initObj && initObj.tagName!="BODY") {
      coord.y-=initObj.scrollTop;
      initObj=initObj.parentNode;
    }
  }
  return coord;
}

/**
* calcul la taille de la page courante
 * @return  tableau pageWidth,pageHeight,windowWidth,windowHeight
 */
function getPageSize(){
	var xScroll, yScroll;
	if (window.innerHeight && window.scrollMaxY) {
		xScroll = document.body.scrollWidth;
		yScroll = window.innerHeight + window.scrollMaxY;
	} else if (document.body.scrollHeight > document.body.offsetHeight){ // all but Explorer Mac
		xScroll = document.body.scrollWidth;
		yScroll = document.body.scrollHeight;
	} else { // Explorer Mac...would also work in Explorer 6 Strict, Mozilla and Safari
		xScroll = document.body.offsetWidth;
		yScroll = document.body.offsetHeight;
	}

	var windowWidth, windowHeight;
	if (self.innerHeight) {	// all except Explorer
		windowWidth = self.innerWidth;
		windowHeight = self.innerHeight;
	} else if (document.documentElement && document.documentElement.clientHeight) { // Explorer 6 Strict Mode
		windowWidth = document.documentElement.clientWidth;
		windowHeight = document.documentElement.clientHeight;
	} else if (document.body) { // other Explorers
		windowWidth = document.body.clientWidth;
		windowHeight = document.body.clientHeight;
	}

	// for small pages with total height less then height of the viewport
	if(yScroll < windowHeight){
		pageHeight = windowHeight;
	} else {
		pageHeight = yScroll;
	}

	// for small pages with total width less then width of the viewport
	if(xScroll < windowWidth){
		pageWidth = windowWidth;
	} else {
		pageWidth = xScroll;
	}


	arrayPageSize = new Array(pageWidth,pageHeight,windowWidth,windowHeight)
	return arrayPageSize;
}

/**
* récupère la valeur d'1 élément
 * @param elmt root
 * @param class to find
 * @return  array
 */
function getElementsByClassName(elmt,className) {
  if (!elmt) return null;
  var elmt = (typeof(elmt)=="object")?elmt:document.getElementById(elmt);
  var elmts = elmt.getElementsByTagName('*');
  var r = new Array();
  for (var j=0;j<elmts.length;j++) {
    if (elmts[j].className==className) r.push(elmts[j]);
  }
  return r;
}

/**
* récupère la valeur d'1 élément
 * @param elmt root
 * @param class to find
 * @return  array
 */
function getElementsByAttribute(elmt,attr,v) {
  if (!elmt) return null;
  var elmt = (typeof(elmt)=="object")?elmt:document.getElementById(elmt);
  var elmts = elmt.getElementsByTagName('*');
  var r = new Array();
  for (var j=0;j<elmts.length;j++) {
    if (elmts[j].getAttribute(attr)==v) r.push(elmts[j]);
  }
  return r;
}

/**
* récupère la valeur d'1 élément
* @param elmt id ou object
 * @return  value
 */
function getValue(elmt) {
  var v = null;
  elmt = (typeof(elmt)=="object")?elmt:document.getElementById(elmt);
  if (elmt) v = (elmt.value!=undefined)?elmt.value:elmt.innerHTML;
  else v = null;
  return v;
}

/**
* affecte la valeur d'1 élément
* @param elmt id ou object
 * @param value
 */
function setValue(elmt,value) {
  elmt = (typeof(elmt)=="object")?elmt:document.getElementById(elmt);
  if (elmt) {
   (elmt.value!=undefined)?elmt.value=value:elmt.innerHTML=value;
  }
}

function trimFields(form) {
	var l = form.getElementsByTagName('INPUT');
	for (var i=0;i<l.length;i++) {
		if (l[i].type!="text" && l[i].type!="password") continue;
		l[i].value = l[i].value.replace(/[\r\n\t]/g,'');
		l[i].value = l[i].value.replace(/(^ +)|( +$)/g,'');
	}
}

function checkEmail(email) {
	return email.toString().match(/^(\w+\-?\.?_?)*\w+@([\w\-]+\.)+\w+$/);
}

function msgAlertBulle(f,o) {
  var id;
  for (var i=0;i<f.length;i++) {
    if (f[i]){
      if (f[i].getAttribute("type")!="hidden" && f[i].getAttribute("type")!="submit" && f[i].getAttribute("type")!="button" && f[i].getAttribute("type")!="image"){
	  	id="bulle_"+f[i].id;
		if(document.getElementById(id)){
	  		document.getElementById(id).style.display="none";
		}
	  }
	}
  }

  for (var v in o) {
    if (typeof(o[v])=="string") {
      if (f[v]) {
		id="bulle_"+f[v].id;
		document.getElementById(id).style.display="block";
	  }
    }
  }
  return false;
}

function msgAlert(f,o) {
  var el = document.createElement("DIV");
  var ch = "<a name='alert'></a><h1>Veuillez renseigner ou corriger les champs signalés ci-dessous :</h1><ul style='text-align:center;'>";
  //var listTd = f.getElementsByTagName("td");
  el.id="formAlert";
  el.style.textAlign="left";
  if (document.getElementById(el.id)) document.getElementById(el.id).parentNode.removeChild(document.getElementById(el.id));
  el.className="form_alert";
  f.insertBefore(el,f.firstChild);

  for (var i=0;i<f.length;i++) {
    if (f[i])
      if (f[i].getAttribute("type")!="submit" && f[i].getAttribute("type")!="button" && f[i].getAttribute("type")!="image") f[i].style.background="white";
  }

  for (var v in o) {
    if (typeof(o[v])=="string") {
      if (o[v]) ch +="<li style='text-align:left;'>"+o[v]+"</li>";
      if (f[v]) f[v].style.background="#FFF22F";
    }
  }
  ch +="</ul>";
  el.innerHTML=ch;
  self.location.hash="#alert";
  return false;
}

function uniqid () {
	var d = new Date();
	var ts = Date.UTC(d.getUTCFullYear(),d.getUTCMonth(),d.getUTCDate(),d.getUTCHours(),d.getUTCMinutes(),d.getUTCSeconds(),d.getUTCMilliseconds());
	var r = Math.floor(Math.random()*1000000);
	return (ts.toString()+r.toString())
}


/*
    json.js
    2006-04-28

    This file adds these methods to JavaScript:

        object.toJSONString()

            This method produces a JSON text from an object. The
            object must not contain any cyclical references.

        array.toJSONString()

            This method produces a JSON text from an array. The
            array must not contain any cyclical references.

        string.parseJSON()

            This method parses a JSON text to produce an object or
            array. It will return false if there is an error.
*/
    //émulation d'innerText pour firefox
/*(function () {
    var m = {
            '\b': '\\b',
            '\t': '\\t',
            '\n': '\\n',
            '\f': '\\f',
            '\r': '\\r',
            '"' : '\\"',
            '\\': '\\\\'
        },
        s = {
            array: function (x) {
                var a = ['['], b, f, i, l = x.length, v;
                for (i = 0; i < l; i += 1) {
                    v = x[i];
                    f = s[typeof v];
                    if (f) {
                        v = f(v);
                        if (typeof v == 'string') {
                            if (b) {
                                a[a.length] = ',';
                            }
                            a[a.length] = v;
                            b = true;
                        }
                    }
                }
                a[a.length] = ']';
                return a.join('');
            },
            'boolean': function (x) {
                return String(x);
            },
            'null': function (x) {
                return "null";
            },
            number: function (x) {
                return isFinite(x) ? String(x) : 'null';
            },
            object: function (x) {
                if (x) {
                    if (x instanceof Array) {
                        return s.array(x);
                    }
                    var a = ['{'], b, f, i, v;
                    for (i in x) {
                        v = x[i];
                        f = s[typeof v];
                        if (f) {
                            v = f(v);
                            if (typeof v == 'string') {
                                if (b) {
                                    a[a.length] = ',';
                                }
                                a.push(s.string(i), ':', v);
                                b = true;
                            }
                        }
                    }
                    a[a.length] = '}';
                    return a.join('');
                }
                return 'null';
            },
            string: function (x) {
                if (/["\\\x00-\x1f]/.test(x)) {
                    x = x.replace(/([\x00-\x1f\\"])/g, function(a, b) {
                        var c = m[b];
                        if (c) {
                            return c;
                        }
                        c = b.charCodeAt();
                        return '\\u00' +
                            Math.floor(c / 16).toString(16) +
                            (c % 16).toString(16);
                    });
                }
                return '"' + x + '"';
            }
        };

    Object.prototype.toJSONString = function () {
        return s.object(this);
    };

    Array.prototype.toJSONString = function () {
        return s.array(this);
    };
})();*/

String.prototype.parseJSON = function () {
    try {
        return !(/[^,:{}\[\]0-9.\-+Eaeflnr-u \n\r\t]/.test(
                this.replace(/"(\\.|[^"\\])*"/g, ''))) &&
            eval('(' + this + ')');
    } catch (e) {
        return false;
    }
};

/* photobox  */
/*
YAHOO.widget.PhotoBox = function(el, userConfig) {
  if (arguments.length > 0) {
    YAHOO.widget.PhotoBox.superclass.constructor.call(this, el, userConfig);
  }
}

// Inherit from YAHOO.widget.Panel
YAHOO.extend(YAHOO.widget.PhotoBox, YAHOO.widget.Panel);

// Define the CSS class for the PhotoBox
YAHOO.widget.PhotoBox.CSS_PHOTOBOX = "photobox";

// Define the HTML for the footer navigation
YAHOO.widget.PhotoBox.NAV_FOOTER_HTML = "<a id=\"$back.id\" href=\"javascript:void(null)\" class=\"back\">&nbsp;</a><a id=\"$next.id\" href=\"javascript:void(null)\" class=\"next\">&nbsp;</a>";

// Initialize the PhotoBox by setting up the footer navigation
YAHOO.widget.PhotoBox.prototype.init = function(el, userConfig) {
  var css = (userConfig["css"])?userConfig["css"]:YAHOO.widget.PhotoBox.CSS_PHOTOBOX;
  YAHOO.widget.PhotoBox.superclass.init.call(this, el);

  this.beforeInitEvent.fire(YAHOO.widget.PhotoBox);
  YAHOO.util.Dom.addClass(this.innerElement, css);

  if (userConfig) {
    userConfig["allphotos"] = userConfig["photos"];
    if (userConfig["draggable"])
      new YAHOO.util.DD(this.innerElement);
    this.cfg.applyConfig(userConfig, true);
  }


  this.setFooter(YAHOO.widget.PhotoBox.NAV_FOOTER_HTML.replace("$back.id",this.id+"_back").replace("$next.id",this.id+"_next"));

  this.renderEvent.subscribe(function() {
    var back = document.getElementById(this.id + "_back");
    var next = document.getElementById(this.id + "_next");

    YAHOO.util.Event.addListener(back, "mousedown", this.back, this, true);
    YAHOO.util.Event.addListener(next, "mousedown", this.next, this, true);

  }, this, true);

  this.initEvent.fire(YAHOO.widget.PhotoBox);
};

// Set up the PhotoBox's "photos" property for setting up the list of photos
YAHOO.widget.PhotoBox.prototype.initDefaultConfig = function() {
  YAHOO.widget.PhotoBox.superclass.initDefaultConfig.call(this);
  this.cfg.addProperty("allphotos", { });
  this.cfg.addProperty("photos", { handler:this.configPhotos, suppressEvent:true });
};
YAHOO.widget.PhotoBox.prototype.currentImage = null;
YAHOO.widget.PhotoBox.prototype.showMe = function(img,id) {
  this.cfg.setProperty("photos",this.cfg.getProperty("allphotos")[id]);
  this.currentImage = img;
  this.show();
  this.setImage(this.currentImage);

  var self;
  self = this;
  setTimeout( function(){ self.center();}, 200 );
}

// Handler executed when the "photos" property is modified
YAHOO.widget.PhotoBox.prototype.configPhotos = function(type, args, obj) {

  var photos = args[0];
  if (photos) {
    this.images = [];
    if (! (photos instanceof Array)) {
      photos = [photos];
    }
    this.currentImage = 0;
    for (var p=0;p<photos.length;p++) {
      var photo = photos[p];
      var img = null;
      if (photo.src != undefined)
      {
        img = new Image();
        img.src = photo.src;
        img.title = photo.caption;
        img.desc = photo.desc;
        img.id = this.id + "_img";
        this.images[this.images.length] = img;
      }
    }
  }
};

// Sets the current image displayed in the PhotoBox to the corresponding image in the photo dataset,
// and determines whether back and forward arrows should be displayed, based on the position in the dataset
YAHOO.widget.PhotoBox.prototype.setImage = function(index) {
  var photos = this.cfg.getProperty("photos");
  if (photos) {
    if (! (photos instanceof Array)) {
      photos = [photos];
    }
    var back = document.getElementById(this.id + "_back");
    var next = document.getElementById(this.id + "_next");
    var img =  document.getElementById(this.id + "_img");
    var title = document.getElementById(this.id + "_title");
    var desc = document.getElementById(this.id + "_desc");

    this.currentImage = index;

    var current = this.images[index];
    var imgNode = document.createElement("IMG");

    imgNode.setAttribute("src",current.src);
    imgNode.setAttribute("title",current.title);
    //imgNode.setAttribute("width",500);
    imgNode.setAttribute("id",current.id);
    img.parentNode.replaceChild((this.browser == "safari"?imgNode:current), img);

    this.body.style.height = "auto";

    title.innerHTML = (current.title)?current.title:"";
    if (desc)
      desc.innerHTML = (current.desc)?current.desc:"";

    if (this.currentImage == 0) {
      back.style.display = "none";
    } else {
      back.style.display = "block";
    }
    if (this.currentImage == (photos.length-1)) {
      next.style.display = "none";
    } else {
      next.style.display = "block";
    }
  }
};

// Navigates to the next image
YAHOO.widget.PhotoBox.prototype.next = function() {
  if (typeof this.currentImage == 'undefined') {
    this.currentImage = 0;
  }
  this.setImage(this.currentImage+1);
};

// Navigates to the previous image
YAHOO.widget.PhotoBox.prototype.back = function() {
  if (typeof this.currentImage == 'undefined') {
    this.currentImage = 0;
  }

  this.setImage(this.currentImage-1);
};

// Overrides the handler for the "modal" property with special animation-related functionality
YAHOO.widget.PhotoBox.prototype.configModal = function(type, args, obj) {
  var modal = args[0];

  if (modal) {
    this.buildMask();

    if (typeof this.maskOpacity == 'undefined') {
      this.mask.style.visibility = "hidden";
      this.mask.style.display = "block";
      this.maskOpacity = YAHOO.util.Dom.getStyle(this.mask,"opacity");
      this.mask.style.display = "none";
      this.mask.style.visibility = "visible";
    }

    if (! YAHOO.util.Config.alreadySubscribed( this.beforeShowEvent, this.showMask, this ) ) {
      this.beforeShowEvent.subscribe(this.showMask, this, true);
    }
    if (! YAHOO.util.Config.alreadySubscribed( this.hideEvent, this.hideMask, this) ) {
      this.hideEvent.subscribe(this.hideMask, this, true);
    }
    if (! YAHOO.util.Config.alreadySubscribed( YAHOO.widget.Overlay.windowResizeEvent, this.sizeMask, this ) ) {
      YAHOO.widget.Overlay.windowResizeEvent.subscribe(this.sizeMask, this, true);
    }
    if (! YAHOO.util.Config.alreadySubscribed( this.destroyEvent, this.removeMask, this) ) {
      this.destroyEvent.subscribe(this.removeMask, this, true);
    }
    this.cfg.refireEvent("zIndex");
  } else {
    this.beforeShowEvent.unsubscribe(this.showMask, this);
    this.beforeHideEvent.unsubscribe(this.hideMask, this);
    YAHOO.widget.Overlay.windowResizeEvent.unsubscribe(this.sizeMask);
  }
};

// Overrides the showMask function to allow for fade-in animation
YAHOO.widget.PhotoBox.prototype.showMask = function() {
  if (this.cfg.getProperty("modal") && this.mask) {
    YAHOO.util.Dom.addClass(document.body, "masked");
    this.sizeMask();

    var o = this.maskOpacity;

    if (! this.maskAnimIn) {
      this.maskAnimIn = new YAHOO.util.Anim(this.mask, {opacity: {to:o}}, 0.25)
      YAHOO.util.Dom.setStyle(this.mask, "opacity", 0);
    }

    if (! this.maskAnimOut) {
      this.maskAnimOut = new YAHOO.util.Anim(this.mask, {opacity: {to:0}}, 0.25)
      this.maskAnimOut.onComplete.subscribe(function() {
                          this.mask.tabIndex = -1;
                          this.mask.style.display = "none";
                          this.hideMaskEvent.fire();
                          YAHOO.util.Dom.removeClass(document.body, "masked");
                          }, this, true);

    }
    this.mask.style.display = "block";
    this.maskAnimIn.animate();
    this.mask.tabIndex = 0;
    this.showMaskEvent.fire();
  }
};

// Overrides the showMask function to allow for fade-out animation
YAHOO.widget.PhotoBox.prototype.hideMask = function() {
  if (this.cfg.getProperty("modal") && this.mask) {
    this.maskAnimOut.animate();
  }
};
*/

//efface un champ
function effacer(elt){
  elt.value='';
}

function showInfo(ref){
	document.getElementById(ref).style.display="block";
}


function hideInfo(ref){
	document.getElementById(ref).style.display="none";
}