//=========================================================
// :::::::::::::::  FONCTIONS GÉNÉRIQUES :::::::::::::::::
// :::::::::      copyright nurun inc 2004      ::::::::::
//=========================================================

function popwin(url,windowname,w,h)
{
PopWin = window.open(url,windowname,'toolbar=0,location=0,directories=0,status=1,menubar=1,scrollbars=1,resizable=0,width=' + w + ',height=' + h + ',top=20,left=20')
}


// fonction de changement de langue
function changelangue(langid,lastid){
	var template = document.location.href.toLowerCase();
	debut  =  template.slice(0,template.lastIndexOf(lastid));
	debut  += langid;
	fin    =  template.slice((template.lastIndexOf(lastid) + 4),template.length);
	document.location.href = (debut + fin);
} 



// Section Roll Over pour le site SETTE
// Selon la valeur de currentBT on fait un mouse out ou non : cf. setNav(bt) ci dessous.
function navRoll(id,state,lang) {
	state = (state) ? "_on" : "_off";
	
	if (currentBT != id)
	{ 
	document.images[id].src = "/" + lang + "/img/" + id + state + ".gif";
	}
	else
	{
	document.images[id].src = "/" + lang + "/img/" + currentBT + "_sel" + ".gif";
	}
}	

//
function navRollSite(id,state) {
	state = (state) ? "_on" : "_off";
	
	if (currentBT != id)
	{ 
	document.images[id].src = "../img/" + id + state + ".gif";
	}
	else
	{
	document.images[id].src = "../img/" + currentBT + "_on" + ".gif";
	}
}	


// setNav(bt) : appelée dans le onload des pages pour laisser le bouton (bt) a 'on'
// var currentBT : on met la variable currentBT a null a chaque appel de la page : elle prendra la valeur de 'bt'
var currentBT = null;

function setNav(bt,lang) 
{
	currentBT = bt;
	navRoll(bt,1,lang);
}

// roll over des selection de langue
function RollAcc(id,state) 
{
	state = (state) ? "_on" : "_off";
	document.images[id].src = "/_static/img/" + id + state + ".gif";
}	

	
	

