
function animationLauncher(src,h,w)
{
	var animation = '<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=7,0,19,0" width="'+w+'" height="'+h+'">';
	animation += '<param name="movie" value="'+src+'">';
	animation += '<param name="quality" value="high">';
	animation += '<embed src="'+src+'" quality="high" pluginspage="http://www.macromedia.com/go/getflashplayer" type="application/x-shockwave-flash" width="'+w+'" height="'+h+'"></embed>';
	animation += '</object>';
	document.getElementById('animation').innerHTML = animation;
}

/* POP UP */
function popSalles(url)
{
	window.open(url,'Plans des salons du Château de la Poterie','toolbar=no,status=no,menubar=no,scrollbars=no,resizable=no,width=600,height=400,left=50,top=50');
}
function popAcces()
{
	window.open('../photos/poterie-acces-2g.jpg','Plans d\'accès au Château de la Poterie','toolbar=no,status=no,menubar=no,scrollbars=no,resizable=no,width=780,height=483,left=50,top=50');
}
function plop(url,w,h)
{
	window.open(url,'','toolbar=no,status=no,menubar=no,scrollbars=no,resizable=no,width='+w+',height='+h+',left=50,top=50');
}
function popup(x,y){
	var	lepopup=document.getElementById('popup');
	
	if(lepopup.style.display=="none"){
		lepopup.style.display="block";
	    var divpopup=lepopup.style.display="none";
		var divpopup=lepopup.innerHTML +="<div class='popupfond'></div>";
			divpopup=lepopup.innerHTML +="<div id='popupimg'><a href='javascript:popup();'><img src='bdd/"+x+"' id='photo'></a><div id='popuptxt'><b>"+y+"</b></div></div>";
	
	   lepopup.style.display="block";
	    //document.getElementById('searchvente').style.display="none";
		
	}else{
		lepopup.style.display="none";
		divpopup=lepopup.innerHTML="";
		//document.getElementById('searchvente').style.display="block";
	}
}



/* FORMULAIRE CONTACT : ALTERNANCE SELECT PARTICULIER / PROFESSIONNEL */
function alternSelect(statut)
{
	var part=document.getElementById('alternEvPart');
	var pro=document.getElementById('alternEvEnt');
	var txt=document.getElementById('txtemp');
	if(statut=='particulier')
	{
		part.style.display="block";
		pro.style.display="none";
		txt.style.display="none";
	}
	if(statut=='entreprise')
	{
		pro.style.display="block";
		part.style.display="none";
		txt.style.display="none";
	}
}



/* SURVOL MENU */
function deployment(obj)
{
	var toaltern=document.getElementById(obj);
	toaltern.style.display=(toaltern.style.display=="none")?"block":"none";
}
function hide(obj)
{
	var tohide=document.getElementById(obj);
	tohide.style.display="none";
}
function show(obj)
{
	var toshow=document.getElementById(obj);
	toshow.style.display="block";
}
function menu(obj,objparent,s)
{
	var menuon=document.getElementById(obj);
	var menuparent=document.getElementById(objparent);
	
	if(s=="P")
	{
		var P_presentation=document.getElementById("ssP-presentation");
		var P_recEnt=document.getElementById("ssP-rec-entreprises");
		var P_recPart=document.getElementById("ssP-rec-particuliers");
		var P_actu=document.getElementById("ssP-actualite");
		var P_contact=document.getElementById("ssP-contact");
		var P_1=document.getElementById("P-presentation");
		var P_2=document.getElementById("P-rec-entreprises");
		var P_3=document.getElementById("P-rec-particuliers");
		
		P_presentation.style.display="none";
		P_recEnt.style.display="none";
		P_recPart.style.display="none";
		P_1.style.borderLeft="1px solid #FFFFFF";
		P_2.style.borderLeft="1px solid #FFFFFF";
		P_3.style.borderLeft="1px solid #FFFFFF";
		menuparent.style.borderLeft="1px solid #1D3C32";
	}
	if(s=="L")
	{
		var L_presentation=document.getElementById("ssL-presentation");
		var L_incentives=document.getElementById("ssL-incentives");
		var L_incoming=document.getElementById("ssL-incoming");
		var L_actu=document.getElementById("ssL-actualite");
		var L_contact=document.getElementById("ssL-contact");
		var L_1=document.getElementById("L-presentation");
		var L_2=document.getElementById("L-incentives");
		var L_3=document.getElementById("L-incoming");
		
		L_presentation.style.display="none";
		L_incentives.style.display="none";
		L_incoming.style.display="none";
		L_1.style.borderLeft="1px solid #FFFFFF";
		L_2.style.borderLeft="1px solid #FFFFFF";
		L_3.style.borderLeft="1px solid #FFFFFF";
		menuparent.style.borderLeft="1px solid #486278";
	}
	menuon.style.display="block";
}
function menuoff(s)
{
	if(s=="P")
	{
		var P_presentation=document.getElementById("ssP-presentation");
		var P_recEnt=document.getElementById("ssP-rec-entreprises");
		var P_recPart=document.getElementById("ssP-rec-particuliers");
		var P_actu=document.getElementById("ssP-actualite");
		var P_contact=document.getElementById("ssP-contact");
		var P_1=document.getElementById("P-presentation");
		var P_2=document.getElementById("P-rec-entreprises");
		var P_3=document.getElementById("P-rec-particuliers");
		
		P_presentation.style.display="none";
		P_recEnt.style.display="none";
		P_recPart.style.display="none";
		P_1.style.borderLeft="1px solid #FFFFFF";
		P_2.style.borderLeft="1px solid #FFFFFF";
		P_3.style.borderLeft="1px solid #FFFFFF";
	}
	if(s=="L")
	{
		var L_presentation=document.getElementById("ssL-presentation");
		var L_incentives=document.getElementById("ssL-incentives");
		var L_incoming=document.getElementById("ssL-incoming");
		var L_actu=document.getElementById("ssL-actualite");
		var L_contact=document.getElementById("ssL-contact");
		var L_1=document.getElementById("L-presentation");
		var L_2=document.getElementById("L-incentives");
		var L_3=document.getElementById("L-incoming");
		
		L_presentation.style.display="none";
		L_incentives.style.display="none";
		L_incoming.style.display="none";
		L_1.style.borderLeft="1px solid #FFFFFF";
		L_2.style.borderLeft="1px solid #FFFFFF";
		L_3.style.borderLeft="1px solid #FFFFFF";
	}
}



function imgFrame(x)
{
	var decor_photo="";
	decor_photo="<table width='100' border='0' cellpadding='0' cellspacing='0' style='display:inline;'>";
	decor_photo+="<tr><td colspan='2'><img src='../img/photo_a.jpg' /></td><td rowspan='2'><img src='../img/photo_b.jpg' /></td></tr>";
    decor_photo+="<tr><td rowspan='2' valign='bottom' style='vertical-align:bottom'><img src='../img/photo_c.jpg' /></td><td><img src='"+x+"' width='548' height='189' name='image1' id='image1' /></td></tr>";
	decor_photo+="<tr><td colspan='2' align='right'><img src='../img/photo_d.jpg' /></td></tr>";
	decor_photo+="</table>";
	document.write(decor_photo);
}



/* MISE EN PLACE FOOTER */
/*function getWindowHeight() {
	var windowHeight = 0;
	if (typeof(window.innerHeight) == 'number') {
		windowHeight = window.innerHeight;
	}
	else {
		if (document.documentElement && document.documentElement.clientHeight) {
			windowHeight = document.documentElement.clientHeight;
		}
		else {
			if (document.body && document.body.clientHeight) {
				windowHeight = document.body.clientHeight;
			}
		}
	}
	return windowHeight;
}
function setFooter() {
	if (document.getElementById) {
		var windowHeight = getWindowHeight();
		if (windowHeight > 0) {
			var contentHeight = document.getElementById('contenu').offsetHeight;
			var footerElement = document.getElementById('bdp');
			var footerHeight  = footerElement.offsetHeight;
			if (windowHeight - (contentHeight + footerHeight) >= 0) {
				footerElement.style.top = (windowHeight - (contentHeight + footerHeight)) + 'px';
			}
			else {
				footerElement.style.top = '0px';
			}
		}
	}
}
window.onload = function() {
	setFooter();
}
window.onresize = function() {
	setFooter();
}*/

