// Pour pouvoir utiliser document.getElementById même avec IE
if(document.all && !document.getElementById) {
    document.getElementById = function(id) {
         return document.all[id];
    }
}

function enableEnter() {
  document.onkeypress = normalKeyProcessing;
  if (document.layers) document.captureEvents(Event.KEYPRESS);
}
function disableEnter() {
  document.onkeypress = enterFireLink;
  if (document.layers) document.captureEvents(Event.KEYPRESS);
}
function normalKeyProcessing(e) {
  return keyCode = document.all? window.event.keyCode:e.which;
}

function Remplace(expr,a,b) {
    var i=0
    while (i!=-1) {
      i=expr.indexOf(a,i);
       if (i>=0) {
          expr=expr.substring(0,i)+b+expr.substring(i+a.length);
          i+=b.length;
       }
}
return expr
}

//Modif TT 23/03/2007
function suppCaracspeciaux(champ){
    champ.value= Remplace(Remplace(Remplace(champ.value,"\u2019","'"),"\u0153","oe"),"\u0152","Oe");
    champ.value = Remplace(champ.value,"\u2026","...")
    champ.value = Remplace(champ.value,"\u2013","-")
    champ.value = Remplace(champ.value,"\u2014","-")
    champ.value = Remplace(champ.value,"\u2010","10")
    champ.value = Remplace(champ.value,"\u2011","11")
    champ.value = Remplace(champ.value,"\u2012","12")
    champ.value = Remplace(champ.value,"\u2015","15")
    champ.value = Remplace(champ.value,"\u201B","`")
    champ.value = Remplace(champ.value,"\u2018","`")
    //champ.value = Remplace(champ.value,"\u0026","&amp;")
}
