function mainmenu2(){
$(" #nav ul ").css({display: "none"}); // Opera Fix
$(" #nav li").hover(function(){
		//$(this).find('ul:first').css({visibility: "visible",display: "none"}).show(500);
		$(this).find('ul:first').css({visibility: "visible",display: "none"}).show("slow");
		},function(){
		$(this).find('ul:first').css({visibility: "hidden"});
		//$(this).find('ul:first').css({visibility: "hidden"}).hide(slow);
		});
}



function accueil(){
	jQuery('#containerflash').cycle({ //  Animation
	    	fx:     'fade',
			//speed:    2000,
	    	//timeout: 3000,
	    	//delay: -2000,
			speed:    3000,
	    	timeout: 1000,
	    	delay: -2000,
	    	slideExpr: '.imga',
			sync:	1
		//after:   onAfter
	});
	
var windowHeight
if (self.innerHeight) {// all except Explorer
windowHeight = self.innerHeight;
} else if (document.documentElement && document.documentElement.clientHeight) { // Explorer 6 Strict Mode
windowHeight = document.documentElement.clientHeight;
} else if (document.body) { // other Explorers
windowHeight = document.body.clientHeight;
};

var tby=document.getElementById("containerize").style.height;
var tby=tby.substring(0,tby.indexOf("p",2));
var y=(windowHeight-tby)/2;
document.getElementById('cont').style.height=y+'px';
};

function site(){
	
	jQuery('.accordeon').accordion({//Menu accordéon
		active: false,
		autoHeight: false,
		header: '.title',
		//navigation: true,
		event: 'click',
		fillSpace: false,
		alwaysOpen: false,
		active: '.selected1'
		//animated: 'easeslide'
	});
};
function montre(id) {
   if (document.getElementById) { document.getElementById(id).style.display=''; 
   }
    else if (document.all) { document.all[id].style.display=''; }
    else if (document.layers) { document.layers[id].display='';}
  }
  
function montre2(id) {
nbrSecondes = 12;
   if (document.getElementById) { document.getElementById(id).style.display=''; 
 //  doc=id;
 //  setTimeout('cache(doc)',nbrSecondes*1000);
   }
    else if (document.all) {doc=id; document.all[id].style.display='';setTimeout('cache(doc)',nbrSecondes*1000); }
    else if (document.layers) {doc=id; document.layers[id].display='';setTimeout('cache(doc)',nbrSecondes*1000); }
  }

function cache(id) {
   if (document.getElementById) { document.getElementById(id).style.display='none'; }
    else if (document.all) { document.all[id].style.display='none'; }
    else if (document.layers) { document.layers[id].display='none'; }
  }
function isBlank(s)
{
	for(var i = 0; i < s.length; i++) 
	{
		var c = s.charAt(i);
		if ((c != ' ')&&(c != '\n')&&(c != '\t')) 
			return false;
	}
	return true;
}
function verifyData(f)
{
	var msg = "";
	var errors = "";
	var nonNumeric = false;
	var oneGreaterZero = false;
	
	for(var i = 0;i < f.length; i++)
	{
		var e = f.elements[i];
		if ((e.type == "text") && (!e.optional))
		{
			if((e.value == null) || (e.value == "") || isBlank(e.value) || isNaN(e.value))
			{
				nonNumeric = true;
				continue;
			}
			else
			{
				if (e.value > 0)
					oneGreaterZero = true;
			}
		}
	}
	
	if (nonNumeric == true)
		errors += "- La quantité doit être un chiffre - At least one quantity is not numeric.\n\n";
		
	if (oneGreaterZero == false)
		errors += "- La quantité doit être supérieure à Zéro. - At least one quantity must be greater than zero.\n\n";
					
	if(!errors) return true;
	msg += "_____________________________________________________________\n\n";
	msg += "Erreur - Merci de corriger puis validez à nouveau.\n";
	msg += "_____________________________________________________________\n\n";
	msg += "The form was not submitted because of the following error(s).\n";
	msg += "_____________________________________________________________\n\n";
	
		
	if (errors) 
	{
		msg += errors;
	}
	
	alert(msg);
	return false;
}
function MM_jumpMenu(targ,selObj,restore){ //v3.0
  eval(targ+".location='"+selObj.options[selObj.selectedIndex].value+"'");
  if (restore) selObj.selectedIndex=0;
}
