// JavaScript Document
function verifff(){
	nb_er = 0;
	
	if ( ( document.acheter1.nb_achat_action.value == "" || document.acheter1.nb_achat_action.value == "Achat" ) && ( document.acheter2.nb_achat_action.value == "" || document.acheter2.nb_achat_action.value == "Achat" ) && ( document.acheter3.nb_achat_action.value == "" || document.acheter3.nb_achat_action.value == "Achat" ) && ( document.acheter4.nb_achat_action.value == "" || document.acheter4.nb_achat_action.value == "Achat" ) && ( document.acheter5.nb_achat_action.value == "" || document.acheter5.nb_achat_action.value == "Achat" ) && ( document.acheter6.nb_achat_action.value == "" || document.acheter6.nb_achat_action.value == "Achat" ) && ( document.acheter7.nb_achat_action.value == "" || document.acheter7.nb_achat_action.value == "Achat" ) && ( document.acheter8.nb_achat_action.value == "" || document.acheter8.nb_achat_action.value == "Achat" ) && ( document.acheter9.nb_achat_action.value == "" || document.acheter9.nb_achat_action.value == "Achat" ) && ( document.acheter10.nb_achat_action.value == "" || document.acheter10.nb_achat_action.value == "Achat" ) && ( document.acheter11.nb_achat_action.value == "" || document.acheter11.nb_achat_action.value == "Achat" ) && ( document.acheter12.nb_achat_action.value == "" || document.acheter12.nb_achat_action.value == "Achat" ) && ( document.acheter13.nb_achat_action.value == "" || document.acheter13.nb_achat_action.value == "Achat" ) ){
       nb_er++;alert('Vous devez indiquer le nombre d\'actions que vous désirez acheter pour ce candidat')
		return false;
    }
	
	/*if(nb_er>0){
		
	}*/
	
}


function change_frame(url,image,targetId){
	document.getElementById("presiframe").src = url;
	if(image==1){
		document.getElementById("navconsole").src = "img/navv.gif";
	}
	if(image==2){
		document.getElementById("navconsole").src = "img/navv2.gif";	
	}
	if(image==3){
		document.getElementById("navconsole").src = "img/navvv2.gif";	
	}
	if(image==4){
		document.getElementById("navconsole").src = "img/navvv.gif";
	}
	//opacity_frame.hide();opacity_frame.toggle();
	
	/*if ( (document.getElementById) && ( target = document.getElementById( 'lecashhh' ) ) ){
		 
  		target = document.getElementById( 'lecashhh' );
		target.style.display = "none";
  			
  	}*/
}

function change_frame2(url,image,targetId){
	document.getElementById("presiframe").src = url;
	if(image==1){
		document.getElementById("navconsole").src = "img/navv.gif";
	}
	if(image==2){
		document.getElementById("navconsole").src = "img/navv2.gif";	
	}
	if(image==3){
		document.getElementById("navconsole").src = "img/navvv2.gif";	
	}
	if(image==4){
		document.getElementById("navconsole").src = "img/navvv.gif";
	}
	//opacity_frame.hide();opacity_frame.toggle();
	
	/*if ( (document.getElementById) && ( target = document.getElementById( 'lecashhh' ) ) ){
		 
  		target = document.getElementById( 'lecashhh' );
		target.style.display = "block";
  			
  	}*/
}

function iframe_menu (){
	document.getElementById('presiframe').style.height='400px';
}

function iframe(dif){
	hauteur = 400 + ( dif * 40 );
	parent.document.getElementById('presiframe').style.height = hauteur+'px';
}

function iiframe(){
	parent.document.getElementById('presiframe').style.height = '400px';
}

function reframe(){
	if(parent.frames.length == 0){
		parent.location.href = "index.php"
	}
}


function ref(){
	
	//alert(parent.document.getElementById('presiframe').src);
	//location.reload();
	document.getElementById("presiframe").src = document.getElementById("presiframe").src;
	
	/*sas_tmstp=Math.round(Math.random()*10000000000);
	sas_masterflag=1;
	
	sas_pageid='2982/21180';      // Page : influence/presidentielles/rg 
	sas_formatid=381;             // Format : Pavé 300x250 300x250 
	sas_target='';                // Targeting 
	SmartAdServer(sas_pageid,sas_formatid,sas_target); */

	//document.getElementById('marcel').innerHTML  = '<scr'+'ipt SRC="http://www.smartadserver.com/call/pubj/' + sas_pageid + '/' + sas_formatid + '/'+sas_master + '/' + sas_tmstp + '/' + escape(sas_target) + '?"></scr'+'ipt>';
}