/**********************************************************************************/
/******************* TOGGLE pour onglets / CHANGER pour police ********************/
/******************fonctions devant être déclenchés dès le début*******************/
/**********************************************************************************/
var $j = jQuery.noConflict();

$j(document).ready(function(){
	$j("div.expand").click(function (e) {
		if ((this.className).indexOf("tabUp") != -1) {
			$j(this).removeClass("tabUp");
			$j(this).addClass("tabDown");
		} else {
			$j(this).removeClass("tabDown");
			$j(this).addClass("tabUp");
		}
		
		var expandableBox = $j(this).next("div.expandableBox");
		expandableBox.slideToggle("slow");
		expandableBox.addClass("open");
		if (window.name != 'print')
			sIFR.replaceElement(named({sSelector: "#boxFull .open h3", sFlashSrc: "flash/commun/gothambook.swf", sColor: "#333333", sWmode: "transparent"}));
	});
	
	/*Ouverture de section fermé visée par des ancre*/
	//ouvrirSection(window.location.href);
	
	/*Pour conserver le grossisement de police, on doit lancer la fonction ici dans le onload*/
	//loadfontsize();
	
	/*****************************************************************/
	/*********************IMG SWAP INFOLETTRE*************************/
	/*****************************************************************/
	
	if($j("#infolettre_link").length)
	{
		$j("#infolettre_link").hover(function(){
			$j("#img_infolettre").attr("src", "images/btn_infolettre_hover.gif");
		},
		function(){
			$j("#img_infolettre").attr("src", "images/btn_infolettre.gif");
		});
	}
	
	if($j("#infolettre_petit").length)
	{
		$j("#infolettre_petit").hover(function(){
			$j("#infolettre_petit_img").attr("src", "images/btn_infolettre_petit_hover.gif");
		},
		function(){
			$j("#infolettre_petit_img").attr("src", "images/btn_infolettre_petit.gif");
		});
	}
});




/**********************************************************************************/
/**************************** ROLLOVER pour les onglets ***************************/
/**********************************************************************************/
	
function overTab(ong)
{
	ong.style.backgroundColor="#f2f2f2"; 
}

function outTab(ong)
{
	ong.style.backgroundColor="#ffffff";
}

/*****************************************************************/
/*********************SEND LINK BY EMAIL*************************/
/*****************************************************************/
function send_to_friend(url)
{
	alert(url);
	window.location = "mailto:&subject=Voici un lien que j'ai trouvé&body=" + url;
}

/**********************************************************************************/
/***************************** REFRESH POUR ACCORDÉON *****************************/
/**********************************************************************************/

function resetAll()
{
	$j("div.expand").removeClass("tabDown");
	$j("div.expand").addClass("tabUp");
	$j("div.expandableBox").slideDown("slow");
	if (window.name != 'print')
		sIFR.replaceElement(named({sSelector: "#boxFull h3", sFlashSrc: "flash/commun/gothambook.swf", sColor: "#333333", sWmode: "transparent"}));
}

/**********************************************************************************/
/********************** FONCTION POUT FERMER TOUS LES ACCORDÉON********************/
/**********************************************************************************/

function toutFermer()
{
	$j("div.expand").removeClass("tabUp");
	$j("div.expand").addClass("tabDown");
	$j("div.expandableBox").slideUp("slow");
	if (window.name != 'print')
		sIFR.replaceElement(named({sSelector: "#boxFull h3", sFlashSrc: "flash/commun/gothambook.swf", sColor: "#333333", sWmode: "transparent"}));
}





