function GetId(id){ return document.getElementById(id); } function GetWidth(id){ return GetId(id).offsetWidth; } function GetHeight(id){ return GetId(id).offsetHeight; } function GetWidthBody(){ return document.body.offsetWidth + document.body.scrollLeft; } function GetHeightBody(){ return document.body.offsetHeight + document.body.scrollTop; } function GetMois(mois){ switch(mois){ case '1': return "Janvier"; case '2': return "Février"; case '3': return "Mars"; case '4': return "Avril"; case '5': return "Mai"; case '6': return "Juin"; case '7': return "Juillet"; case '8': return "Aout"; case '9': return "Septembre"; case '10': return "Octobre"; case '11': return "Novembre"; case '12': return "Décembre"; } } function affDiv(id){ GetId("mask").style.display = "block"; GetId("mask").style.width = GetWidthBody(); GetId("mask").style.height = GetHeightBody(); GetId(id).style.display = "block"; GetId(id).style.top = (((screen.height - GetHeight(id)) / 2))+'px'; GetId(id).style.left = ((screen.width - GetWidth(id)) / 2)+'px'; } function maskDiv(id){ GetId(id).style.display = "none"; GetId("mask").style.display = "none"; } function GetXmlHTTP(){ if(window.XMLHttpRequest){ return new XMLHttpRequest(); }else if(window.ActiveXObject){ return new ActiveXObject("Microsoft.XMLHTTP"); }else{ return(false); } } function LoadXml(xml,typeReponse,champs){ var xmlObj = GetXmlHTTP(); xmlObj.open("POST",xml,false) xmlObj.setRequestHeader('Content-Type','application/x-www-form-urlencoded'); xmlObj.send(champs) if(xmlObj.readyState == 4){ if(xmlObj.status == 200){ if(typeReponse == 0){ return xmlObj.responseText; }else{ return xmlObj.responseXML; } }else{ } }else{ return(false); } }