nbImageHautRnd = 5;

Jour = new Array ("Dimanche","Lundi","Mardi","Mercredi","Jeudi","Vendredi","Samedi");
Mois = new Array ("janvier", "février", "mars", "avril", "mai", "juin", "juillet", "août", "septembre", "octobre", "novembre", "décembre");
NbJourMois = new Array(31, 28, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31);
d = new Date();
annee = d.getYear();
if (annee < 1990) {annee=annee+1900}
strRien = Jour[d.getDay()] + " le " + d.getDate() + " " + Mois[d.getMonth()] + " " + annee;
strNada = "";
lemois = d.getMonth();

evjour = new Array();
evmois = new Array();
evannee = new Array();
evcourtTexte = new Array();
evlongTexte = new Array();

NbEvenems = 0;


function AjouteEv(_j, _m, _a, _ct, _lt)
{
	evjour = evjour.concat(_j);
	evmois = evmois.concat(_m);
	evannee = evannee.concat(_a);
	evcourtTexte = evcourtTexte.concat(_ct);
	evlongTexte = evlongTexte.concat(_lt);
	NbEvenems = NbEvenems + 1;
}


AjouteEv(8, 7, 2003, "19h30 chez les Kennedy", "<table cellpadding='0' cellspacing='0' border='0' width='100%'><tr><td align='left'>Réunion JVA chez les Kennedy!</td><td align='right'></td></tr></table>"); 
AjouteEv(31, 9, 2003, "19h30 à <a href=\'EVA.html\'>EVA</a>", "<table cellpadding='0' cellspacing='0' border='0' width='100%'><tr><td align='left'>19h30 Soirée d\'intercession à <a href=\'EVA.html\'>Église Vie Abondante</a></td><td align='right'></td></tr></table>"); 
AjouteEv(7, 10, 2003, "19h30 à <a href=\'EVA.html\'>EVA</a>", "<table cellpadding='0' cellspacing='0' border='0' width='100%'><tr><td align='left'>19h30 Soirée de jeunesse à <a href=\'EVA.html\'>Église Vie Abondante</a> Bienvenue à tous! <br><br>Entrée Libre</td><td align='right'></td></tr></table>"); 
AjouteEv(7, 0, 2005, "19h30 Soirée JVA à <a href=\'EVA.html\'>EVA</a>", "19h30 Soirée de jeunesse à <a href=\'EVA.html\'>Église Vie Abondante</a>"); 
AjouteEv(14, 0, 2005, "19h30 Soirée JVA à <a href=\'EVA.html\'>EVA</a>", "19h30 Soirée de jeunesse à <a href=\'EVA.html\'>Église Vie Abondante</a>"); 
AjouteEv(21, 0, 2005, "19h30 Soirée JVA à <a href=\'EVA.html\'>EVA</a>", "19h30 Soirée de jeunesse à <a href=\'EVA.html\'>Église Vie Abondante</a>"); 
AjouteEv(28, 0, 2005, "19h30 Soirée JVA à <a href=\'EVA.html\'>EVA</a>", "19h30 Soirée de jeunesse à <a href=\'EVA.html\'>Église Vie Abondante</a>"); 
AjouteEv(4, 1, 2005, "19h30 Soirée JVA à <a href=\'EVA.html\'>EVA</a>", "19h30 Soirée de jeunesse à <a href=\'EVA.html\'>Église Vie Abondante</a> avec Jérémie Vitrano"); 
AjouteEv(11, 1, 2005, "19h30 Soirée JVA à <a href=\'EVA.html\'>EVA</a>", "19h30 Soirée de jeunesse à <a href=\'EVA.html\'>Église Vie Abondante</a> avec Simon Fournier"); 
AjouteEv(18, 1, 2005, "19h30 Contre-Courant", "19h30 Contre-Courant au Carrefour Chrétien de la Capitale"); 
AjouteEv(25, 1, 2005, "19h30 Soirée JVA à EVA", "19h30 Soirée de jeunesse à l'Église Vie Abondante... Soirée Spéciale!"); 
AjouteEv(4, 2, 2005, "19h30 Soirée JVA à EVA", "19h30 Soirée de jeunesse à l'Église Vie Abondante... <br>Message spécial de pasteur Benoit."); 
AjouteEv(11, 2, 2005, "19h30 Soirée JVA à EVA", "19h00 Soirée contact à l'Église Vie Abondante<br><img border=0 src='annSC050311mini.jpg'"); 
AjouteEv(18, 2, 2005, "19h30 Soirée JVA à EVA", "19h30 Soirée de jeunesse à l'Église Vie Abondante"); 
AjouteEv(25, 2, 2005, "19h30 Soirée JVA à EVA", "19h00 Soirée spéciale à l'Église Vie Abondante...<br>Présentation du film 'Le Corps'"); 
AjouteEv(1, 3, 2005, "19h30 Soirée JVA à EVA", "19h30 Soirée contact à l'Église Vie Abondante"); 
AjouteEv(8, 3, 2005, "19h30 Soirée JVA à EVA", "19h30 Soirée de jeunesse à l'Église Vie Abondante... <br>Les parents sont invités!"); 
AjouteEv(15, 3, 2005, "19h30 Soirée JVA à EVA", "19h30 Contre-Courant au Carrefour Chrétien de la Capitale"); 
AjouteEv(22, 3, 2005, "19h30 Soirée JVA à EVA", "19h30 Soirée de jeunesse à l'Église Vie Abondante... <br>Message spécial de pasteur Benoit."); 
AjouteEv(29, 3, 2005, "19h30 Soirée JVA à EVA", "19h30 Soirée de jeunesse à l'Église Vie Abondante... <br>Message spécial de pasteur Benoit."); 
AjouteEv(6, 4, 2005, "19h30 Soirée JVA à EVA", "Soirée Contact pour les jeunes à l'Église Vie Abondante... "); 
AjouteEv(13, 4, 2005, "19h30 Soirée JVA à EVA", " Soirée pour les jeunes à l'Église Vie Abondante...<br> Message par Simon Fournier :o)"); 
AjouteEv(20, 4, 2005, "19h30 Soirée JVA à EVA", "20-21-22 mai Conférence Jeunesse/Youth Convention (CJYC) <br> Pour info: <a target='_blank' href='http://www.paradoxproject.ca'>www.paradoxproject.ca</a> "); 
AjouteEv(27, 4, 2005, "19h30 Soirée JVA à EVA", "Soirée pour les jeunes à l'Église Vie Abondante...<br> Message par pasteur Benoit :o)"); 
AjouteEv(3, 5, 2005, "19h30 Soirée JVA à EVA", "Soirée JVA avec un prédicateur invité:<br>Éric Lefebvre"); 
AjouteEv(10, 5, 2005, "19h30 Soirée JVA à EVA", "Soirée pour les jeunes à l'Église Vie Abondante...<br> Message par pasteur Benoit :o)"); 
AjouteEv(17, 5, 2005, "19h30 Soirée JVA à EVA", "Soirée Contre-Courant au CCC à 19h30<br>Louange par le groupe Unité, Tabitha Lemaire  <a target='_blank' href='http://www.tabithalemaire.com/'>http://www.tabithalemaire.com/</a><br>et mini-concert de prière"); 
AjouteEv(24, 5, 2005, "19h30 Soirée JVA à EVA", "Soirée spéciale (détails à venir)"); 
AjouteEv(1, 6, 2005, "19h30 Soirée JVA à EVA", "Réunion de jeunesse annulée<br>Bonne fête du Canada!"); 
AjouteEv(8, 6, 2005, "19h30 Soirée JVA à EVA", "JVA au Café Rencontre du Centre-Ville<br>Heure: 19h30<br>Prédication: Pasteur Dominique<br>Chants: Nicole Béliveau et la JVA"); 
AjouteEv(15, 6, 2005, "19h30 Soirée JVA à EVA", "Réunion de jeunesse annulée<br><br>Possibilité toutefois de vous inscrire à la retraite de notre frère Désiré Yankey qui aura lieu au Camp de l'Arche les 15 et 16 juillet au coût de 35$/personne ou 90$/famille de 3 enfants<br><br> Thème: Génération J<br>Invité: Pasteur Christian Lachance<br>Équipe de louange: JVA (Jérémie, Simon & Jonathan)<br>Date limite d'inscription: 3 juillet 2005<br>Pour information et inscription: 418.485.6228<br>Courriel: <a href='mailto:aepsh@hotmail.com'>aepsh@hotmail.com</a>"); 
AjouteEv(8, 6, 2005, "19h30 Soirée JVA à EVA", "JVA à l'ÉVA à 19h30"); 
AjouteEv(22, 6, 2005, "19h30 Soirée JVA à EVA", "JVA à l'ÉVA à 19h30"); 
AjouteEv(29, 6, 2005, "19h30 Soirée JVA à EVA", "Soirée 'Beach' chez les Delorme dès 18h00<br>1109 François Lemire (Cap-Rouge)"); 
AjouteEv(5, 7, 2005, "19h30 Soirée JVA à EVA",  "JVA à l'ÉVA à 19h30");
AjouteEv(12, 7, 2005, "19h30 Soirée JVA à EVA", "Réunion de jeunesse annulée"); 
AjouteEv(19, 7, 2005, "19h30 Soirée JVA à EVA", "Réunion de jeunesse annulée"); 
AjouteEv(26, 7, 2005, "19h30 Soirée JVA à EVA", "JVA à l'ÉVA à 19h30"); 
AjouteEv(2, 8, 2005, "19h30 Soirée JVA à EVA", "JVA à l'ÉVA à 19h30"); 



function ValDate(_j, _m, _a)
{
	laValDate = 0;
	laValDate = laValDate + ((_a - 2003) * 365);
	laValDate = laValDate + (_m * 31);
	laValDate = laValDate + _j;
	return laValDate;
}

function DansLimites(_j1, _m1, _a1, _j2, _m2, _a2, _j3, _m3, _a3)
{
	laVal1 = ValDate(_j1, _m1, _a1);
	laVal2 = ValDate(_j2, _m2, _a2);
	laVal3 = ValDate(_j3, _m3, _a3);
	if(laVal1 <= laVal2 && laVal2 <= laVal3)
	{
		return 1;
	}
	else return 0;
}

function CourtTexte(_jour, _mois, _annee)
{
	for(cti = 0; cti < NbEvenems; cti++)
	{
		if(_jour == evjour[cti] && _mois == evmois[cti] && _annee == evannee[cti])
		{
			return evcourtTexte[cti];
		}
	}
	return "";
}

function LongTexte(_jour, _mois, _annee)
{
	for(cti = 0; cti < NbEvenems; cti++)
	{
		if(_jour == evjour[cti] && _mois == evmois[cti] && _annee == evannee[cti])
		{
			return evlongTexte[cti];
		}
	}
	return "";
}

function SetCookie(sName, sValue)
{
  date = new Date();
  document.cookie = sName + "=" + escape(sValue) + "; expires=Fri, 31 Dec 2050 23:59:59 GMT;";
}

function GetCookie(sName)
{
  var aCookie = document.cookie.split("; ");
  for (var i=0; i < aCookie.length; i++)
  {
    var aCrumb = aCookie[i].split("=");
    if (sName == aCrumb[0]) 
      return unescape(aCrumb[1]);
  }
  return null;
}

v_prenom = GetCookie("C_Prenom")
if(v_prenom == null){v_prenom = "ami"}

function Prenom()
{
document.write(v_prenom);
}

function DecMois()
{
	lemois = lemois - 1;
	if(lemois == -1) {lemois = 11; annee = annee - 1;}
}

function IncMois()
{
	lemois = lemois + 1;
	if(lemois == 12) {lemois = 0; annee = annee + 1;}
}

function DecJour(_jour)
{
	retjour = _jour - 1;
	if(retjour <= 0)
	{
		DecMois();
		retjour = NbJourMois[lemois];
	}
	return retjour;
}

function IncJour(_jour)
{
	retjour = _jour + 1;
	if(retjour > NbJourMois[lemois])
	{
		IncMois();
		retjour = 1;
	}
	return retjour;
}

function IncJrSemaine(_jrSemaine)
{
	_jrSemaine = _jrSemaine + 1;
	if(_jrSemaine >= 7) _jrSemaine = 0;
	return _jrSemaine;
}


function Aujourdhui()
{
	Aujourd = LongTexte(d.getDate(), d.getMonth(), annee);
	if(Aujourd.length > 0) document.write("<h3>Aujourd'hui...</h3><b>" + Aujourd + "</b>");
}

function CetteSemaine()
{
	strSemaine = "";
	strActJour = "";
	jrsemaine = d.getDay();
	jourmois = d.getDate();
	lemois = d.getMonth();
	for(csi = 0; csi < 6; csi++)
	{
		jourmois = IncJour(jourmois);
		jrsemaine = IncJrSemaine(jrsemaine);
		strActJour = LongTexte(jourmois, lemois, annee);
		if(strActJour.length > 0)
		{
			strSemaine = strSemaine + "<b>" + Jour[jrsemaine] + " le " + jourmois + " " + Mois[lemois] + ": </b><br><font size=2>" + strActJour + "</font><br><br>"
		}
	}
	if(strSemaine.length > 0)document.write("<table width='100%' border='1' cellspacing='0' cellpadding='5' bordercolor='" + c1 + "'><tr><td align='center'><h3>Cette semaine...</h3><font size='2'>" + strSemaine + "</font></td></tr></table>");
}


function ListeEvenements()
{
	strSemaine = "";
	strActJour = "";
	jrsemaine = d.getDay();
	varvraimentbidon = jrsemaine + 1;
	jourmois = d.getDate();
	lemois = d.getMonth();
	for(csi = 0; csi < (35 - varvraimentbidon); csi++)
	{
		jourmois = IncJour(jourmois);
		jrsemaine = IncJrSemaine(jrsemaine);
		strActJour = LongTexte(jourmois, lemois, annee);
		if(strActJour.length > 0)
		{
			strSemaine = strSemaine + "<h3>" + Jour[jrsemaine] + " le " + jourmois + " " + Mois[lemois] + ": </h3><b>" + strActJour + "</b>"
		}
	}
	if(strSemaine.length > 0)document.write(strSemaine);
}

function ElMenu(_num, _select, _top, _left, _href, _imgoff, _imgon, _w, _h)
{
	if(_num == _select)
	{
		document.write("<div style='top: " + _top + "; left: " + _left + "; position: absolute; z-index: 4; visibility: show;'><a href='" + _href + "'><img id='Mn" + _num + "' width=" + _w + " height=" + _h + " border=0 src='" + _imgon + "'></a></div>");
	}
	else
	{
		document.write("<div style='top: " + _top + "; left: " + _left + "; position: absolute; z-index: 4; visibility: show;'><a href='" + _href + "'><img id='Mn" + _num + "' width=" + _w + " height=" + _h + " border=0 src='" + _imgoff + "' onmouseover='Allume(" + _num + ");' onmouseout='Eteind(" + _num + ");'></a></div>");
	}
}

//<OBJECT codeBase=http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,0,0 height='100%' width='100%' classid=clsid:D27CDB6E-AE6D-11cf-96B8-444553540000 VIEWASTEXT><PARAM NAME='Src' VALUE='images/hautjva.swf'><PARAM NAME='Play' VALUE='-1'><PARAM NAME='Quality' VALUE='High'><EMBED src='images/hautjva.swf' quality='high' HEIGHT='28' TYPE='application/x-shockwave-flash' PLUGINSPAGE='http://www.macromedia.com/go/getflashplayer'></EMBED></OBJECT>

intnbpageloadee = GetCookie("NbPageL");
if(intnbpageloadee == null)intnbpageloadee = 1;
intnbpageloadee++;
intnbpageloadee = intnbpageloadee % 99;
SetCookie("NbPageL", intnbpageloadee);

function MonRandom2(le_max2)
{
	daterand = new Date();
	monnombrerandom = daterand.getMilliseconds();
	monnombrerandom = (monnombrerandom % le_max2) + 1;
	return monnombrerandom;
}

function MonRandom(le_max)
{
	monnombrerandom = ((intnbpageloadee + (MonRandom2(le_max) - 1)) % le_max) + 1;
	return monnombrerandom;
}

function ImageHautRnd()
{
	return "<img border=0 src='imghaut" + MonRandom(nbImageHautRnd) + ".png'>";
}



function menu(select)
{
	document.write("<div style='top: 0; left: 19; position: absolute; z-index: 4; visibility: show;'><IFrame width='852' height='28' src='images/hautjva.swf' frameborder='0' ALLOWTRANSPARENCY borderColor='#00274A'></IFrame></div>");
	ElMenu(1, select, 526, 16, "Activites.html", "btActivitesoff.png", "btActiviteson.png", 122, 35);
	ElMenu(2, select, 562, 17, "Questions.html", "btQuestionsoff.png", "btQuestionson.png", 193, 34);
	ElMenu(3, select, 597, 16, "TrancheVie.html", "btTrancheVieoff.png", "btTrancheVieon.png", 239, 40);
	ElMenu(4, select, 514, 799, "Lieux.html", "btLieuxoff.png", "btLieuxon.png", 122, 35);
	ElMenu(5, select, 550, 738, "Parents.html", "btParentsoff.png", "btParentson.png", 184, 35);
	ElMenu(6, select, 587, 685, "Contacts.html", "btContactsoff.png", "btContactson.png", 237, 39);
//	document.write("<div style='top: 526; left: 16; position: absolute; z-index: 4; visibility: show;'><a href='Activites.html'><img id='Mn1' border=0 src='images/btActivitesoff.png'></a></div>");
//	document.write("<div style='top: 562; left: 17; position: absolute; z-index: 4; visibility: show;'><a href='Questions.html'><img id='Mn2' border=0 src='btQuestionoff.png'></a></div>");
//	document.write("<div style='top: 597; left: 16; position: absolute; z-index: 4; visibility: show;'><a href='TrancheVie.html'><img id='Mn3' border=0 src='images/btTrancheVieoff.png'></a></div>");
//	document.write("<div style='top: 514; left: 799; position: absolute; z-index: 4; visibility: show;'><a href='Lieux.html'><img id='Mn4' border=0 src='images/btLieuxoff.png'></a></div>");
//	document.write("<div style='top: 550; left: 738; position: absolute; z-index: 4; visibility: show;'><a href='Parents.html'><img id='Mn5' border=0 src='images/btParentsoff.png'></a></div>");
//	document.write("<div style='top: 587; left: 685; position: absolute; z-index: 4; visibility: show;'><a href='Contacts.html'><img id='Mn6' border=0 src='images/btContactsoff.png'></a></div>");
//	Allume(select);
	document.write("<div style='top: 30; left: 607; position: absolute; z-index: 4; visibility: show;'><a href='page1.html'><img width=285 height=128 border=0 src='rien.png'></a></div>");
if(select == 2)
{
	document.write("<OBJECT style='top: 27; left: 0; position: absolute; z-index: 4; visibility: show;' classid='clsid:D27CDB6E-AE6D-11cf-96B8-444553540000' codebase='http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,0,0' WIDTH='928' HEIGHT='150' id='Mod2' VIEWASTEXT><PARAM NAME=movie VALUE='mod2.swf'> <PARAM NAME=quality VALUE=high> <PARAM NAME=wmode VALUE=transparent> <PARAM NAME=bgcolor VALUE=#000000> <EMBED src='Mod2.swf' quality=high wmode=transparent bgcolor=#000000  WIDTH='928' HEIGHT='150' NAME='Mod2' ALIGN='' TYPE='application/x-shockwave-flash' PLUGINSPAGE='http://www.macromedia.com/go/getflashplayer'></EMBED></OBJECT>");
//	document.write("<div style='top: 47; left: 389; position: absolute; z-index: 3; visibility: show;'>" + ImageHautRnd() + "</div>");
}
else if(select == 3)
{
	document.write("<OBJECT style='top: 26; left: 0; position: absolute; z-index: 4; visibility: show;' classid='clsid:D27CDB6E-AE6D-11cf-96B8-444553540000' codebase='http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,0,0' WIDTH='928' HEIGHT='150' id='Mod2' VIEWASTEXT><PARAM NAME=movie VALUE='mod2.swf'> <PARAM NAME=quality VALUE=high> <PARAM NAME=wmode VALUE=transparent> <PARAM NAME=bgcolor VALUE=#000000> <EMBED src='Mod2.swf' quality=high wmode=transparent bgcolor=#000000  WIDTH='928' HEIGHT='150' NAME='Mod2' ALIGN='' TYPE='application/x-shockwave-flash' PLUGINSPAGE='http://www.macromedia.com/go/getflashplayer'></EMBED></OBJECT>");
//	document.write("<div style='top: 46; left: 389; position: absolute; z-index: 3; visibility: show;'>" + ImageHautRnd() + "</div>");
}
else
{
	document.write("<OBJECT style='top: 25; left: 0; position: absolute; z-index: 4; visibility: show;' classid='clsid:D27CDB6E-AE6D-11cf-96B8-444553540000' codebase='http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,0,0' WIDTH='928' HEIGHT='150' id='Mod2' VIEWASTEXT><PARAM NAME=movie VALUE='mod2.swf'> <PARAM NAME=quality VALUE=high> <PARAM NAME=wmode VALUE=transparent> <PARAM NAME=bgcolor VALUE=#000000> <EMBED src='Mod2.swf' quality=high wmode=transparent bgcolor=#000000  WIDTH='928' HEIGHT='150' NAME='Mod2' ALIGN='' TYPE='application/x-shockwave-flash' PLUGINSPAGE='http://www.macromedia.com/go/getflashplayer'></EMBED></OBJECT>");
//	document.write("<div style='top: 45; left: 389; position: absolute; z-index: 3; visibility: show;'>" + ImageHautRnd() + "</div>");
}
}

function Allume(choix)
{
	if(choix == 1)
	{
		Mn1.src = "btActiviteson.png";
	}
	else if(choix == 2)
	{
		Mn2.src = "btQuestionson.png";
	}
	else if(choix == 3)
	{
		Mn3.src = "btTrancheVieon.png";
	}
	else if(choix == 4)
	{
		Mn4.src = "btLieuxon.png";
	}
	else if(choix == 5)
	{
		Mn5.src = "btParentson.png";
	}
	else if(choix == 6)
	{
		Mn6.src = "btContactson.png";
	}
}

function Eteind(choix)
{
	if(choix == 1)
	{
		Mn1.src = "btActivitesoff.png";
	}
	else if(choix == 2)
	{
		Mn2.src = "btQuestionsoff.png";
	}
	else if(choix == 3)
	{
		Mn3.src = "btTrancheVieoff.png";
	}
	else if(choix == 4)
	{
		Mn4.src = "btLieuxoff.png";
	}
	else if(choix == 5)
	{
		Mn5.src = "btParentsoff.png";
	}
	else if(choix == 6)
	{
		Mn6.src = "btContactsoff.png";
	}
}