function progression(){
	lBar_menu = new Array();
	lBar_menu[0] = '';
	lAffiche_menu ='';
	lBar_menu_deb = '::: Vous êtes ici :<A CLASS="progression" HREF="javascript:load(0)">&nbsp;&nbsp;Home</A>&nbsp;<';
	lBar_menu_end = '';
	lCount = 0;
	for (lCount=1; lCount<=(parent.gNiveau) ; lCount++){
		lBar_menu_end = '&nbsp\;' + parent.gSujet[lCount];
		if (lCount == 1) {
			lAffiche_menu = lBar_menu_deb + lBar_menu_end;
			lBar_menu[lCount] = '';
		} else {
			if((typeof parent.gSujet[lCount-1]) == 'undefined'){
				lBar_menu[lCount]= '';
			}else{
				lBar_menu[lCount] = lBar_menu[lCount - 1] + '&nbsp\;<A CLASS="progression" href="javascript:load(' + (lCount-1) + ')">' + parent.gSujet[lCount-1] + '</A>&nbsp;<';		
			}
		} // end if
		lAffiche_menu = lBar_menu_deb + lBar_menu[lCount] + lBar_menu_end;	
	} // end for;
	document.write(lAffiche_menu);
}

//navigation
function load(p_Niveau){
	parent.gNiveau=p_Niveau;
	if(p_Niveau==0){
		parent.lmprincipal77.location.href = 'index.php';
	}else{
		parent.lmprincipal77.location.href = parent.gPrincipal[parent.gNiveau];
	}
}

function load_page(p_Page,p_Sujet,p_Niveau){
	parent.gNiveau=p_Niveau;
	parent.gSujet[parent.gNiveau]=p_Sujet;
	parent.gPrincipal[parent.gNiveau]=p_Page;
	parent.lmprincipal77.location.href=p_Page;
}

function load_page2(p_Page,p_Sujet,p_Pageavant,p_Sujetavant,p_Niveau){
	parent.gNiveau=p_Niveau;
	parent.gSujet[parent.gNiveau-1]=p_Sujetavant;
	parent.gPrincipal[parent.gNiveau-1]=p_Pageavant;
	parent.gSujet[parent.gNiveau]=p_Sujet;
	parent.gPrincipal[parent.gNiveau]=p_Page;
	parent.lmprincipal77.location.href=p_Page;
}

function charge_frame(p_Suj){
	if (window.name != 'lmprincipal77'){
		var l_Page=document.URL.substring(document.URL.indexOf(".ch/")+4);
		if (p_Suj == '' || typeof(p_Suj)=='undefined'){
			p_Suj='';
		}
		var param='page='+l_Page+'&sujet='+p_Suj;		
		window.location.href="index.php?" + param;
	}
}

//images
function preload(p_Img){
	p_Img = new Image();
	p_Img.src = 'images/'+p_Img;
}

function change_image(img_nom,img_src) { 
	document[img_nom].src = img_src;
}

function agrandissement(image,titre,width,height) {
	var fenetre_param='left='+(screen.width/2-width/2)+',top='+(screen.height/2-height/2)+',directories=no,status=no,scrollbars=no,resizable=no,menubar=no,';
	fenetre_param+='width='+width+',height='+height;
	fenetre_photo = window.open('','',fenetre_param);
	fenetre_photo.document.open();
	fenetre_photo.document.writeln('<HTML><HEAD><TITLE>' + titre + '</TITLE>');
	fenetre_photo.document.writeln('<LINK HREF="fichiers/_styles_photos.css" REL="stylesheet" TYPE="text/css"></HEAD>');
	fenetre_photo.document.writeln('<BODY><CENTER><P><IMG SRC="images/' + image + '.jpg" BORDER="1"></P><P>' + titre + '</P>');
	fenetre_photo.document.writeln('<P><A HREF="javascript:this.window.close()"><SMALL>Fermer cette fen&ecirc;tre</SMALL></A></P>');
	fenetre_photo.document.writeln('</CENTER></BODY></HTML>');
	fenetre_photo.focus();
}

function popup_center(image,titre,width,height) {
	var fenetre_param='left='+(screen.width/2-width/2)+',top='+(screen.height/2-height/2)+',directories=no,status=no,scrollbars=no,resizable=no,menubar=no,';
	fenetre_param+='width='+width+',height='+height;
	fenetre_photo = window.open('','',fenetre_param);
	fenetre_photo.document.open();
	fenetre_photo.document.writeln('<HTML><HEAD><TITLE>' + titre + '</TITLE>');
	fenetre_photo.document.writeln('<LINK HREF="fichiers/_styles_photos.css" REL="stylesheet" TYPE="text/css"></HEAD>');
	fenetre_photo.document.writeln('<BODY><CENTER><P><IMG SRC="images/' + image + '"></P><P>' + titre + '</P>');
	fenetre_photo.document.writeln('<P><A HREF="javascript:this.window.close()"><SMALL>Fermer cette fen&ecirc;tre</SMALL></A></P>');
	fenetre_photo.document.writeln('</CENTER></BODY></HTML>');
	fenetre_photo.document.close();
	fenetre_photo.focus();
}

function mesure(_MesurePro, _page){
	scr_w = screen.width;
	scr_h = screen.height;
	color = screen.colorDepth;
	ref = escape(window.document.referrer);
	document.write("<IMG src='http://www.direct-stats.com/cgi-bin/pro/stats/ludo77/marqueur.pl/"+ "?page="+ _page+ "&n="+ Math.round (Math.random () * 1000000000000000)+ "&reso_w="+ scr_w+ "&reso_h="+ scr_h+ "&color="+ color+ "&referer="+ ref+"' border=0>");
}

function verifform(){
	if(document.formulaire.Nom.value == ""){
		alert("Veuillez entrer votre nom !");
		document.formulaire.Nom.focus();
		return false;
	}
	if(document.formulaire.Prenom.value == ""){
		alert("Veuillez entrer votre prénom !");
		document.formulaire.Prenom.focus();
		return false;
    	}
	if(document.formulaire.Localite.value == ""){
		alert("Veuillez entrer votre NP et votre localité !");
		document.formulaire.Localite.focus();
		return false;
	    }
	if(document.formulaire.Email.value == "" || document.formulaire.Email.value.indexOf('@') == -1 || document.formulaire.Email.value.indexOf('.') == -1){
		alert("Veuillez entrer une adresse e-mail correcte !");
		document.formulaire.Email.focus();
		return false;
	    }
	parent.travail.location.href = 'sou_club_reponse.php';
}
