var now = new Date();
var year = now.getYear();
if (year<1000) year+=1900;
var month = now.getMonth() + 1;
var day = now.getDay() + 1;
var date = ((now.getDate()<10) ? "0" : "")+ now.getDate();
if(month == 1)  Month="Janvier";
if(month == 2)  Month="F&eacute;vrier";
if(month == 3)  Month="Mars";
if(month == 4)  Month="Avril";
if(month == 5)  Month="Mai";
if(month == 6)  Month="Juin";
if(month == 7)  Month="Juillet";
if(month == 8)  Month="Août";
if(month == 9)  Month="Septembre";
if(month == 10) Month="Octobre";
if(month == 11) Month="Novembre";
if(month == 12) Month="Décembre";
if(day == 1)  Day="Dimanche";
if(day == 2)  Day="Lundi";
if(day == 3)  Day="Mardi";
if(day == 4)  Day="Mercredi";
if(day == 5)  Day="Jeudi";
if(day == 6)  Day="Vendredi";
if(day == 7)  Day="Samedi";
var todaysDate =(Day +" "+date +" "+ Month +" "+year);
//
function initArray() {  
  this.length = initArray.arguments.length
  for (var i = 0; i < this.length; i++)
  this[i+1] = initArray.arguments[i]
}
var JourArray = new initArray("Dimanche","Lundi","Mardi","Mercredi","Jeudi","Vendredi","Samedi");
var MoisArray = new initArray("Janvier","F&eacute;vrier","Mars","Avril","Mai","Juin","Juillet","Ao&ucirc;t","Septembre","Octobre","Novembre","D&eacute;cembre");
var DateJour = new Date();

function DateEnClaire() {
document.write("<span>" + JourArray[(DateJour.getDay()+1)] + " " + DateJour.getDate() + " " + MoisArray[(DateJour.getMonth()+1)] + " " + (DateJour.getFullYear()+0)+"</span>");
}
//
function MM_preloadImages() { //v3.0
  var d=document; if(d.images){ if(!d.MM_p) d.MM_p=new Array();
    var i,j=d.MM_p.length,a=MM_preloadImages.arguments; for(i=0; i<a.length; i++)
    if (a[i].indexOf("#")!=0){ d.MM_p[j]=new Image; d.MM_p[j++].src=a[i];}}
}
//
function ImageduJour() {
    var ImgArray = new initArray("photos_gal/IMG_0155.jpg","photos_gal/gal_photo6.jpg","photos_gal/fleurs_32.jpg","photos_gal/Img_010.jpg",
                                 "photos_gal/img_012.jpg","photos_gal/gal_photo1.jpg","photos_gal/diap29.jpg");
if (navigator.appName == 'Microsoft Internet Explorer')
  document.write('<IMG SRC="' + ImgArray[(DateJour.getDay()+1)] + '" onload=this.style.filter='+"'"+'progid:DXImageTransform.Microsoft.Shadow(color=#000000,direction=135,strength=8)'+"'" + ' WIDTH=307' + ' HEIGHT=209'  + ' ALT="' + 'Accès à toutes les photos du site ...' + '" BORDER=0>')
else
  document.write('<IMG class=ombrage SRC="' + ImgArray[(DateJour.getDay()+1)] + '" WIDTH=307' + ' HEIGHT=209'  + ' ALT="' + 'Accès à toutes les photos du site ...' + '" BORDER=0><br><br>')
    
}
function LibImage() {
	var LibArray = new initArray("Panorama depuis la Jungfrau - Suisse","Parc de la Vanoise ...","Macro-photographie ...","Bruges et ses canaux - Belgique",
                                "Les jardins de Claude Monet ...","Massif du Mont-Blanc ...","Massif des Ecrins ...");
                                
	document.write('<center><font face="Arial" size="2" color="' + '#808080' + '"><b>' + LibArray[(DateJour.getDay()+1)] + '</b></font></center>');
}
//
function SetCookie (name, value) {
	var argv=SetCookie.arguments;
	var argc=SetCookie.arguments.length;
	var expires=(argc > 2) ? argv[2] : null;
	var path=(argc > 3) ? argv[3] : null;
	var domain=(argc > 4) ? argv[4] : null;
	var secure=(argc > 5) ? argv[5] : false;
	document.cookie=name+"="+escape(value)+
		((expires==null) ? "" : ("; expires="+expires.toGMTString()))+
		((path==null) ? "" : ("; path="+path))+
		((domain==null) ? "" : ("; domain="+domain))+
		((secure==true) ? "; secure" : "");
}
function getCookieVal(offset) {
	var endstr=document.cookie.indexOf (";", offset);
	if (endstr==-1)
      		endstr=document.cookie.length;
	return unescape(document.cookie.substring(offset, endstr));
}
function GetCookie (name) {
	var arg=name+"=";
	var alen=arg.length;
	var clen=document.cookie.length;
	var i=0;
	while (i<clen) {
		var j=i+alen;
		if (document.cookie.substring(i, j)==arg)
                        return getCookieVal (j);
                i=document.cookie.indexOf(" ",i)+1;
                        if (i==0) break;}
	return null;
}
function heure() { 
var Maintenant = new Date(); 
var fuseau = Maintenant.getTimezoneOffset();
var heures = Maintenant.getHours(); 
var minutes = Maintenant.getMinutes(); 
var secondes = Maintenant.getSeconds();
heures = heures + (fuseau/60)+1;
//heure été
var annee = Maintenant.getFullYear();
for (i=31; i >24; i--) {
dimanche = new Date(annee, 2, i);
if (dimanche.getDay()==0) break;
}
for (i=31; i >24; i--) {
dimanche2 = new Date(annee, 9, i);
if (dimanche2.getDay()==0) break;
}
if (Maintenant >= dimanche && Maintenant < dimanche2) heures = heures + 1;
//heure été
heures = ((heures < 10) ? " 0" : " ") + heures;
minutes = ((minutes < 10) ? ":0" : ":") + minutes; 
secondes = ((secondes < 10) ? ":0" : ":") + secondes; 
//document.formhorloge.horloge.value = heures + minutes + secondes;
setTimeout("heure()",1000); 
}
function Heureloc() {
	document.write("<span class='dateCopy'><b><font face='Book Antiqua' size=2>" + heures + ":" + minutes + ":" + secondes+"</font></b></span>");
}
//
function description(texte) {
    window.status = texte; 
    return(true);
}
function effaceetat() {
    window.status='';
    return(true);
}
function ejs_img_fx(img){	
	if(img && img.filters && img.filters[0]){
		img.filters[0].apply();
		img.filters[0].play();
	}
}
function ejs2_img_fx(img){	
	if(img && img.filters && img.filters[0]){
		img.filters[0].apply();
		img.filters[0].play();
	}
}
//
function UR_Start() 
{
	UR_Nu = new Date;
	UR_Indhold = showFilled(UR_Nu.getHours()) + ":" + showFilled(UR_Nu.getMinutes()) + ":" + showFilled(UR_Nu.getSeconds());
	document.getElementById("ur").innerHTML = UR_Indhold;
	setTimeout("UR_Start()",1000);
}
function showFilled(Value) 
{
	return (Value > 9) ? "" + Value : "0" + Value;
}
//
function getXMLHttpRequest() { 
  var xhr = null; 

  if(window.XMLHttpRequest || window.ActiveXObject) { 
    if(window.ActiveXObject) { 
      try { 
        xhr = new ActiveXObject("Msxml2.XMLHTTP"); 
      } catch(e) { 
        xhr = new ActiveXObject("Microsoft.XMLHTTP"); 
      } 
    } else { 
      xhr = new XMLHttpRequest(); 
    } 
  } else { 
    alert("Votre navigateur ne supporte pas l'objet XMLHTTPRequest..."); 
    return null; 
  } 
  return xhr; 
}
//
function file(fichier)
{
  if(window.XMLHttpRequest)             // FIREFOX
    xhr_object = new XMLHttpRequest();
  else if(window.ActiveXObject)        // IE
    xhr_object = new ActiveXObject("Microsoft.XMLHTTP");
  else
    return(false);
  xhr_object.open("GET", fichier, false);
  xhr_object.send(null);
  if(xhr_object.readyState == 4)
    return(xhr_object.responseText);
  else
    return(false);
}
