<!-- dissimulation du contenu du SCRIPT pour les anciens browsers

function f_DisableSubmit(lo_button)
{
  if (lo_button.value=='...')
  {
	alert("Faut pas m'bousculer !!");
    return false;
  } 
  else
  {
    lo_button.value='...........';
    return true;
    lo_button.disabled=true // Ceci empeche IE de soumettre le formulaire!!!
  }
}

// Suppression des blancs à gauche et à droite d'un string
function strip(theString) {
    for (i = 0; i < theString.length && theString.charAt(i) == ' '; i++);
    if (i == theString.length) return('');
    theString = theString.substring(i,theString.length);
    for (i = theString.length - 1; i > 0  && theString.charAt(i) == ' '; i--);
    theString = theString.substring(0,i+1);
    return(theString);
}

// Vérifie qu'un string ne contient que certains caractères
function verifChars(theString, verifString) {
    for (i = 0; i < theString.length; i++) {
        if (verifString.indexOf(theString.charAt(i)) < 0) return(false);
    }
    return(true);
}
// Mise en forme condensée d'un String pour pouvoir effectuer des recherches alphabétiques.
function upperTrans(theString) {
    var strEx = " ´'-"; // caractères exclus (à supprimer)
    var strIn = "àâäéèêëîïöôùûüçñ"; // caractères à modifier
    var strOu = "AAAEEEEIIOOUUUCN";
    var i, car; str = '';
    for (i = 0; i < theString.length; i++) {
        car = theString.charAt(i);
        if (strEx.indexOf(car) == -1) {
            index = strIn.indexOf(car);
            if (index > -1) str += strOu.charAt(index); else str += car;
        }
    }
    if (str != '') str = str.toUpperCase();
    return(str);
}

// Validation d'un champ numérique dans un <FORM>
function validNumeric(theChamp,theLabel,obligatoire,minValue,maxValue) {
    var val = theChamp.value;
    if (theLabel == '' || theLabel == null) theLabel = "La zone indiquée par le curseur";
    if (strip(val) == '') {
        if (obligatoire) {
            window.alert(theLabel + " est obligatoire !");
            theChamp.focus();
            return(false);
        }
        else return(true);
    }
    if (! verifChars(val, "-0123456789")) {
        window.alert(theLabel + " doit être numérique !");
       theChamp.focus();
        return(false);
    }
    val = parseInt(strip(val),10);
    if (minValue != null) {
        if (val < minValue) {
            window.alert(theLabel + " doit être supérieur ou égal à " + minValue + " !");
            theChamp.focus();
            return(false);
        }
    }
    if (maxValue != null) {
        if (val > maxValue) {
            window.alert(theLabel + " doit être inférieur ou égal à " + maxValue + " !");
            theChamp.focus();
            return(false);
        }
    }
    return(true);
}


// Vérifier qu'un champ est obligatoire dans un <FORM>
function validObligatoire(theChamp,theLabel) {
    var val = theChamp.value;
    if (theLabel == '' || theLabel == null) theLabel = "La zone indiquée par le curseur";
    if (strip(val) == '') {
        window.alert(theLabel + " est obligatoire !");
        theChamp.focus();
        return(false);
    }
    return(true);
}

// Obtention du navigateur utilisé
function uwGetBrowser() {
    var A = navigator.userAgent.toUpperCase();
    if (A.indexOf("MSIE") != -1) return('IE');
    else if (A.indexOf("MOZILLA") != -1 && A.indexOf("COMPATIBLE") == -1) return('NET');
    return('');
}
// fin de dissimulation du contenu du SCRIPT pour les anciens browsers -->
