// JavaScript Document
function getElementsByClass(searchClass, node, tag) { 
var classElements = new Array(); 
if ( node == null ) 
node = document; 
if ( tag == null ) 
tag = '*'; 
var els = node.getElementsByTagName(tag); 
var elsLen = els.length; 
var pattern = new RegExp("(^|\\s)"+searchClass+"(\\s|$)"); 
for (i = 0, j = 0; i < elsLen; i++) { 
if ( pattern.test(els[i].className) ) { 
classElements[j] = els[i]; 
j++; 
} 
} 
return classElements; 
} 

function tailleFonte() { 
cibles = getElementsByClass('par'); 
ciblesM = getElementsByClass('LinkMenu'); 
ciblesT = getElementsByClass('titre'); 
for (i = 0; i < cibles.length; i++) { 
        cibles[i].style.fontSize = 'small'; 
        } 
for (i = 0; i < ciblesM.length; i++) { 
        ciblesM[i].style.fontSize = '12px'; 
        } 
for (i = 0; i < ciblesT.length; i++) { 
        ciblesT[i].style.fontSize = 'large'; 
        } 
    } 
function tailleFontX() { 
cibles = getElementsByClass('par'); 
ciblesM = getElementsByClass('LinkMenu'); 
ciblesT = getElementsByClass('titre'); 
for (i = 0; i < cibles.length; i++) { 
        cibles[i].style.fontSize = 'large'; 
        } 
for (i = 0; i < ciblesM.length; i++) { 
        ciblesM[i].style.fontSize = '15px'; 
        } 
for (i = 0; i < ciblesT.length; i++) { 
        ciblesT[i].style.fontSize = 'x-large'; 
        } 
    } 
function tailleFontXX() { 
cibles = getElementsByClass('par'); 
ciblesM = getElementsByClass('LinkMenu'); 
ciblesT = getElementsByClass('titre'); 
for (i = 0; i < cibles.length; i++) { 
        cibles[i].style.fontSize = 'x-large'; 
        } 
for (i = 0; i < ciblesM.length; i++) { 
        ciblesM[i].style.fontSize = '15px'; 
        } 
for (i = 0; i < ciblesT.length; i++) { 
        ciblesT[i].style.fontSize = 'x-large'; 
        } 
    } 

function validFormContact() {
	if(document.getElementById('nom').value != ''){
		if(document.getElementById('tel').value != ''){
			if(document.getElementById('mail').value != ''){
				if(document.getElementById('sujet').value != ''){
					if(document.getElementById('mess').value != ''){
						return true ;
					} else {
						alert('Veuillez saisir votre message.');
						return false ;
					}
				} else {
					alert('Veuillez indiquer le sujet de votre message.');
					return false ;
				}
			} else {
				alert('Veuillez indiquer votre adresse mail.');
				return false ;
			}
		} else {
			alert('Veuillez indiquer votre numero de telephone.');
			return false ;
		}
	} else {
		alert('Veuillez indiquer votre nom.');
		return false ;
	}
}

function closeConfirm() {
	document.getElementById('confirmC').style.display = 'none' ;
}

function affichP(txt){
	document.getElementById('prochain').style.display = 'block' ;
	document.getElementById('nameProchain').innerHTML = txt ;
}
function cacheP(){
	document.getElementById('prochain').style.display = 'none' ;
}
