/**** FAQ ****/
function hideFaq(){
	var allResponses = document.getElementById('responseFaq').getElementsByTagName('div');
	for(var i=1;i<allResponses.length+1;i++){
		var nom=allResponses[i-1].id;	
		if(nom.indexOf("FaqQ")!=-1){		
			eval("document.getElementById('"+nom+"').className= 'displayNone'");	
		}
	}
}

function hideLinkQuestion(){
	var Questions = document.getElementById('questionFaq').getElementsByTagName('li');
	for(var i=1;i<Questions.length+1;i++){
		eval("document.getElementById('Question"+i+"').className= ''");
	}
}

function showFaq(){
	var myFAQ = document.getElementById('questionFaq');
	if(myFAQ != undefined){
		hideFaq();
		var allQuestions = document.getElementById('questionFaq').getElementsByTagName('li');
	
			for(var i=0;i<allQuestions.length;i++){
				allQuestions[i].onclick = function(){
					hideLinkQuestion();
					document.getElementById('selectQuestion').className='displayNone';
					hideFaq();
					this.firstChild.className='linkSimple';
					var myRef = this.firstChild.href;
					myRef = myRef.split('#');
					myRef = myRef[1];
					document.getElementById(myRef).className='displayBlock';
				}
			}
		}
	}
/**** FIN FAQ ****/

function showInteret(){
	var radioShow = document.getElementById('offreOui');
	var radioHide = document.getElementById('offreNon')
	var blockInteret = document.getElementById('blockInteret');
	
	if(blockInteret != undefined){
		blockInteret.className='displayNone';
		if (radioShow.checked){
			document.getElementById('blockInteret').className='displayBlock';
		}
		radioShow.onclick = function(){
			if (radioShow.checked){
				document.getElementById('blockInteret').className='displayBlock';
			}
		}
		
		radioHide.onclick = function(){
			if (radioHide.checked){
				document.getElementById('blockInteret').className='displayNone';
			}
		}
	}
}


addLoadListener(showInteret);
addLoadListener(showFaq);
