// Gestion de messages et de l'affichage de la date en fonction de la date du jour.

var date_statement="";
var time_statement="";
var today=new Date();
var month="";
var day="";

function todays_date() {
var month=today.getMonth();
var day_of_week=today.getDay();
date_statement=""
document.month=""
month++; // So it's now between 1 - 12.
if(month==1) {
january(today.getDate());
document.month="Janvier";
}
if(month==2) {
february(today.getDate());
document.month="F&eacute;vrier"; 
}
if(month==3) {
march(today.getDate());
document.month="Mars";
}
if(month==4) {
april(today.getDate());
document.month="Avril";
}
if(month==5) {
may(today.getDate());
document.month="Mai";
}
if(month==6) {
june(today.getDate());
document.month="Juin";
}
if(month==7) {
july(today.getDate());
document.month="Juillet";
}
if(month==8) {
august(today.getDate());
document.month="Ao&ucirc;t"; 
}
if(month==9) {
september(today.getDate());
document.month="Septembre";
}
if(month==10) {
october(today.getDate());
document.month="Octobre";
}
if(month==11) {
november(today.getDate());
document.month="Novembre";
}
if(month==12) {
december(today.getDate());
document.month="D&eacute;cembre";
}
document.day=""
if(day_of_week==0)
document.day="Dimanche";
if(day_of_week==1)
document.day="Lundi";
if(day_of_week==2)
document.day="Mardi";
if(day_of_week==3)
document.day="Mercredi";
if(day_of_week==4)
document.day="Jeudi";
if(day_of_week==5)
document.day="Vendredi";
if(day_of_week==6)
document.day="Samedi";
}

function january(date) {
if(date==1)
date_statement="";
}

function february(date) {
if(date==1)
date_statement="";
}

function march(date) {
if(date==1)
date_statement="";
}

function april(date) {
if(date==1)
date_statement="";
if(date==25)
date_statement="";
}

function may(date) {
if(date==1)
date_statement="";
}

function june(date) {
if(date==1)
date_statement="";
}

function july(date) {
if(date==1)
date_statement="";
}

function august(date) {
if(date==1)
date_statement="";
}

function september(date) {
if(date==1)
date_statement="";
}

function october(date) {
if(date==1)
date_statement="";
}

function november(date) {
if(date==1)
date_statement="";
}

function december(date) {
if(date==1)
date_statement="";
}

function time_of_day() {
var time=today.getHours();
time_statement=""
if(time>=6 && time<8)
time_statement="Bonjour,"
if(time>=8 && time<12)
time_statement="Bonne matin&eacute;e,"
if(time>=12 && time<13)
time_statement="Bon app&eacute;tit,"
if(time>=13 && time<17)
time_statement="Bon apr&egrave;s-midi,"
if(time>=17 && time<18)
time_statement="Bon fin d'apr&egrave;s-midi,"
if(time>=18 && time<20)
time_statement="Bonsoir et bon app&eacute;tit,"
if(time>=20 && time<22)
time_statement="Bonsoir,"
if(time>=22 || time<6)
time_statement="Bonne nuit,"
}

function getFonc(mois,jour) {
  	var ar = new Array(12)
 	ar[0] = getFete01(jour)
  	ar[1] = getFete02(jour)
	ar[2] = getFete03(jour)
	ar[3] = getFete04(jour)
	ar[4] = getFete05(jour)
	ar[5] = getFete06(jour)
	ar[6] = getFete07(jour)
	ar[7] = getFete08(jour)
	ar[8] = getFete09(jour)
	ar[9] = getFete10(jour)
	ar[10] = getFete11(jour)
	ar[11] = getFete12(jour)
	return ar[mois]
}

function getFete01(num)
{var fetes = new Array(
	"Jour de l'An", "Basile", "Geneviève", "Odilon", "Edouard", "Melaine",
   	"Raymond", "Lucien", "Alix", "Guillaume", "Paulin", "Tatiana", "Yvette",
   	"Nina", "R&eacute;mi", "Marcel", "Roseline", "Prisca", "Marius", "Sébastien",
   	"Agnès", "Vincent", "Barnard", "François", "Paul", "Paule", "Angèle",
   	"Thomas", "Gildas", "Martine", "Marcelle","","","");
   	return fetes[num]}

function getFete02(num)
{var fetes = new Array(
	"Ella", "Pr&eacute;sention", "Blaise", "V&eacute;ronique", "Agathe", "Gaston", "Eug&eacute;nie", "Jacqueline",
   	"Apolline", "Arnaud", "ND Lourdes", "F&eacute;lix", "B&eacute;atrice", "Valentin", "Claude",
	"Julienne", "Alexis", "Bernadette", "Gabin", "Aim&eacute;e", "Cendres", "Isabelle",
	"Lazare", "Modeste", "Roméo", "Nestor", "Honorine", "Romain", "Auguste","","","","","");
   	return fetes[num]}

function getFete03(num)
{var fetes = new Array(
	"Aubin", "Charles", "Gu&eacute;nol&eacute;", "Casimir", "Olive", "Colette", "F&eacute;licit&eacute;", "Jean", "Françoise",
	"Vivien", "Rosine", "Justine", "Rodrigue", "Mathilde", "Louise", "B&eacute;n&eacute;dicte", "Patrice",
	"Cyrille", "Joseph", "Herbert", "Cl&eacute;mence", "Léa", "Victorien", "Karine", "Anne", "Larissa",
	"Habib", "Gontran", "Gwladys", "Am&eacute;d&eacute;e", "Benjamin","","","");
   	return fetes[num]}

function getFete04(num)
{var fetes = new Array(
	"Hugues", "Sandrine", "Richard", "Isidore", "Irène", "Marcellin", "JB.de la S", "Julie", "Gautier",
	"Fulbert", "Stanislas", "Jules", "Ida", "Maxime", "Paterne", "Benoït", "Anicet", "Parfait",
	"Emma", "Odette", "Anselme", "Alexandre", "Georges", "Fidèle", "Marc", "Alida", "Zita", "Val&eacute;rie",
	"Catherine", "Robert","","","");
	return fetes[num]}

function getFete05(num)
{var fetes = new Array(
	"Fête du travail", "Boris", "Philippe", "Sylvain", "Judith", "Prudence", "Gisèle", "Armistice 1945", "Pâcome", "Solange",
	"Estelle", "Achille", "Rolande", "Matthias", "Denise", "Honor&eacute;", "Pascal", "Eric", "Yves", 
	"Bernardin", "Constantin", "Emile", "Didier", "Donatien", "Sophie", "B&eacute;ranger", "Augustin", 
	"Germain", "Aymar", "Ferdinand", "Visitation","","","");
   return fetes[num]}

function getFete06(num)
{var fetes = new Array(
	"Justin", "Blandine", "K&eacute;vin", "Clotilde", "Igor", "Norbert", "Gilbert", "Médard", "Diane", "Landry",
   "Yolande", "Guy", "Antoine", "Elis&eacute;e", "Germaine", "J.F.R&eacute;gis", "Herv&eacute;", "Léonce", "Romuald",
   "Silvère", "Rodolphe", "Alban", "Audrey", "Baptiste", "Prosper", "Anthelme", "Fernand", "Ir&eacute;n&eacute;e", 
   "Paul/Pierre", "Martial","","","");
   return fetes[num]}

function getFete07(num)
{var fetes = new Array(
	"Thierry", "Martinien", "Thomas", "Florent", "Antoine", "Mariette", "Raoul", "Thibaut", "Amandine", "Ulrich",
	"Benoït", "Olivier", "Joël", "Camille", "Donald", "ND.Carmel", "Caroline", "Frédéric", "Arsène",
	"Marina", "Victor", "Madeleine", "Brigitte", "Christine", "Jacques", "Anne", "Nathalie", "Samson",
	"Marthe", "Juliette", "Ignace","","","");
   return fetes[num]}

function getFete08(num)
{var fetes = new Array(
	"Alphonse", "Julien", "Lydie", "Jean Marie", "Oswald", "Transf.", "Gaétan", "Dominique", "Amour", "Laurent", 
   "Claire", "Clarisse", "Hippolyte", "Evrard", "Alfred", "Armel", "Hyacinthe", "Hélène", "Jean",
   "Bernard", "Christophe", "Fabrice", "Rose", "Barthélémy", "Louis", "Natacha", "Monique", "Augustin.",
   "Sabine", "Fiacre", "Aristide","","","");
   return fetes[num]}

function getFete09(num)
{var fetes = new Array(
	"Gilles", "Ingrid", "Grégoire", "Rosalie", "Raïssa", "Bertrand", "Reine", "Nativité", "Alain", "Inés", 
   "Adelphe", "Apollinaire", "Aimé", "Ste-Croix", "Roland", "Edith", "Renaud", "Nadège", "Amélie",
   "Davy", "Mathieu", "Maurice", "Constant", "Thècle", "Hermann", "Côme", "Vincent", "Venceslas",
   "Gabriel", "Jérôme","","",""); 
   return fetes[num]}

function getFete10(num)
{var fetes = new Array(
	"Thérèse", "Léger", "Gérard", "François", "Fleur", "Bruno", "Serge", "Pélagie", "Denis", "Ghislain", 
	"Firmin", "Wilfried", "Géraud", "Juste", "Thérèse", "Edwige", "Baudoin", "Luc", "René", "Adeline", 
	"Céline", "Elodie", "Jean", "Florentin", "Enguerran", "Dimitri", "Emeline", "Simon", "Narcisse", 
	"Bienvenue", "Quentin","","","");
   return fetes[num]}

function getFete11(num)
{var fetes = new Array(
	"Toussaint", "Défunts", "Hubert", "Charles", "Sylvie", "Bertille", "Carine", "Geoffroy", "Théodore", 
	"Léon", "Martin", "Christian", "Brice", "Sidoine", "Albert", "Marguerite", "Elisabeth", "Aude", "Tanguy",
	"Edmond", "Présentat.", "Cécile", "Clément", "Augusta", "Catherine", "Delphine", "Séverin", "Jacques",
	"Saturnin", "André","","","");
   	return fetes[num]}

function getFete12(num)
{var fetes = new Array(
	"Florence", "Viviane", "François", "Barbara", "Gérald", "Nicolas", "Ambroise", "Imm.Conc.", "Pierre",
	"Romaric", "Daniel", "Chantal", "Lucie", "Odile", "Ninon", "Alice", "Gaël", "Gatien", "Urbain", "Abraham",
   "Pierre", "Françoise", "Armand", "Adèle", "Noël", "Etienne", "Jean", "Innocents", "David", "Roger",
   "Sylvestre","","","");
   return fetes[num]}

/***********************************************/
/* Affichage d'une page via un popup           */
/***********************************************/

function popup(page) {
window.open(page, '', 'top=80, left=80, width=860, height=550, resizable=yes, toolbar=no, scrollbars=yes, status=no');
}

function maxi_800x600() {
			 parent.window.moveTo(0,0);
			 resize(800,600);
}
