function nav2Gauche(number) {

var currentnav="nav2_"+number;
if (number==1) newnav="nav2_5";
	else newnav="nav2_"+(number-1);

document.getElementById(currentnav).style.display='none';
document.getElementById(newnav).style.display='block';

}


function nav2Droite(number) {

var currentnav="nav2_"+number;
if (number==5) newnav="nav2_1";
	else newnav="nav2_"+(number+1);

document.getElementById(currentnav).style.display='none';
document.getElementById(newnav).style.display='block';


}

function alternLangue(want) {

var tronc="file:///D:/_AAA/_sites/atelierpromeneur/site";
var adresse=window.location.href;
var want='/'+want+'/';

if (adresse.match(want)) {
//alert('reload');
window.location.href=adresse;
}
else {
//alert('alterne');
	if(want=='/fr/') {
	var depart='/en/';	
	}
	else {
	var depart='/fr/';
	}
adresse=adresse.replace(depart,want);
window.location.href=adresse;
}
//window.location=adresse;
//alert(want);
}


function contactOpen() {

document.getElementById('contact').innerHtml="OULALA";
document.getElementById('contact').style.display='block';

}

function contactClose() {

document.getElementById('contact').style.display='none';

}


function nav2GaucheOld(currentnav) {

document.getElementById(currentnav).style.display='none';
document.getElementById('nav2bis').style.display='block';

}

function chnageLangue(currentnav) {
var adresse=window.location.href;
alert(adresse);

}


function glisseagauche(currentnav) {

Effect.SlideUp('nav2',{scaleX:1,scaleY:0,scaleContent:0,duration:1.0,queue:'end'});
Effect.SlideDown('nav2bis',{scaleX:1,scaleY:0,scaleContent:0,duration:2.0,queue:'end'});

}



function echanger (b, s) {
		
			if (document.images)
				b.src = s;
		}


function show(obj) {
	Element.setStyle(obj, { display:'block'});	
}                       

function hide(obj) {
	Element.setStyle(obj, { display:'none'});		
}


function replaceSideNav() {
	if(typeof sIFR == "function"){				    
		sIFR.replaceElement("#subnavigation>a>.subnavlinktext", named({sFlashSrc: "common/flash/MrsEavesRoman.swf", sColor: "#531402"}));
	};
}

function replaceWithFlash(el) {
	if(typeof sIFR == "function"){				    
		sIFR.replaceElement(el, named({sFlashSrc: "common/flash/MrsEavesRoman.swf", sColor: "#531402"}));
	};
}

var hasOpenPopup = 0;
// this is for opening pop-up windows
function openPopup( url, name, widgets, openerUrl ){
        var host = location.hostname;
        if (window == top) { window.top.name = "opener"; }
        var popupWin = window.open( url, name, widgets );
        if(popupWin) {gasOpenPopup = 1;}
        if ( popupWin && popupWin.opener ) {
                if ( openerUrl )
                {
                        popupWin.opener.location = openerUrl;
                }
        }
        if ( popupWin) {
                popupWin.focus();
        }

		return false;
}


function getHeightOfElement(el) {
	if (el.currentStyle){
        return el.offsetHeight;                                 //ie
    }else{
        return Element.getStyle(el,"height").replace("px","");  //moz
    }
}

function hiveware_enkoder(){var i,j,x,y,x=
"x=\"|A&7-e]|A49jqE`&5$|=<kDp:?A```&::B0=99!D><$%22>:2)6=;9D>7!5==9;>9>jo=>" +
"m@==khy=@99>=7H{=m/>>99lq=:0B99j;>=m)6<<9l=9>6);kj<=<k66;@%22k=:;<B;m```&>" +
">j:=?9:}A=8m=:><++=@;=99>?|=8c)9l6Ay=kr9:8D!i=@wg=m=;9=met9j>l:lli,99=m:m=" +
"|-9j?:97=9j<=sv999j9=@,m=j<k<7>A4=l:;:9=?m9m@@9j=7|==2p<k98o=lir={=jnu@kx=" +
";:9ls9l?>:m?5!9</=8/-Cp9jB=;!n>7<:DplA|=7=@/y=2g99l?vm=7e9jvGB.>8.<?sh:D=9" +
"%22B<iE:8>>c)=x,:9mm69==-9j17i:=l7<k?m::=@i{?j,=;=;zi>n@>;7:|z=86=@-n5!:m2" +
"=>/A>.=;,.7=8=7>j/l=?}99/@wh=8A9jWxjz=kl<>vm:u=9|D=rk:89j2%22<2j:9vk$0:=s9" +
"jqG9D=<2<kle:p=9B%22;vG>?>?)6=sh=>i76B99,=@n-00=l9=<#}`&3=@p/?nAiz=;y)=ep," +
"|2;69=<glevEB%22=>Dx,4--.><.B?|A|2=?mv=wyfwx;y/>7v,5-?pD;m7}A++?B==pCjsv,m" +
"=l!5=A4?m@@sl=h|2pirun=j{kxl?mo:lBp/A8-!:92D9}/A|2j:7<kwyfwx0$=mmv,m06v=:y" +
"/-?#js=lqD9v,mA6mTh=@?m@|2{o=;5pirkxt=<pul?m/A>;/!>8-!}/:5s>>A|2wylu=mnfwx" +
"v,{=ko3m06-?=kp2=#}A}2m:7=:wyfwx0B=94v,n-?&?nAizep,|2glevEx,4--?|A|2wyfwxv" +
",5-?}A++?jsv,mA4?m@|2pirkxl?m/A54-!}/A|2wyfwxv,m09-?#jsv,mA9?m@|2pirkxl?m/" +
"A54-!}/A|2wyfwxv,m09-?#}A}2wyfwxv,n-?\";y='';x=unescape(x);for(i=0;i<x.len" +
"gth;i++){j=x.charCodeAt(i)-4;if(j<32)j+=94;y+=String.fromCharCode(j)}y";
while(x=eval(x));}

function custompageInit() {
	/*
	This function is a placeholder.
	Do not put any code in here that you actually want to execute.
	*/
	return false;
}


/*
addLoadEvent: This is used to add functions to the window load event observer.
For example, if you have a function defined as:

	function somethingInit() {
		...
	}

You would put this function call at the end of that page's .js
(Note that you leave off the parenthesis, using only the function name as the argument.)

	addLoadEvent(somethingInit);

*/
function addLoadEvent(func) {
	var oldcustomInit = custompageInit;
	custompageInit = function() {
		oldcustomInit();
		func();
	};	
}


function init() {
	custompageInit();
}
