
function lit_cook(nom) {
    var deb,fin
    deb = document.cookie.indexOf(nom + "=")
    if (deb >= 0) {
        deb += nom.length + 1
        fin = document.cookie.indexOf(";",deb)
        if (fin < 0) fin = document.cookie.length
        return unescape(document.cookie.substring(deb,4))
    }
    return ""
}

function setEwsCookie (nom,valeur,jours) {
    var expDate = new Date();
    expDate.setTime(expDate.getTime() + (jours * 24 * 3600 * 1000));
    document.cookie = nom + "=" + escape(valeur)+"-EN; expires=" + expDate.toGMTString() +"; javahere=yes; path=/ ";
	
	document.location.href=top.location.href;
}

function setEwsCookieForce (nom,valeur,jours) {
    var expDate = new Date();
    expDate.setTime(expDate.getTime() + (jours * 24 * 3600 * 1000));
    document.cookie = nom + "=" + escape(valeur)+ "; expires=" + expDate.toGMTString() +"; javahere=yes; path=/ ";
	
	document.location.href=top.location.href;
}
