
function DelWishlist( action ,panier_save_id) {
	
	$.get(BBVars.pagesURL+"compte_panier.cfm?action="+action+"&panier_save_id=" + panier_save_id);
	delTR("#ligne"+panier_save_id, "55px");

}
function trim(myString)
{
	return myString.replace(/^\s+/g,'').replace(/\s+$/g,'')
} 

function afficheListProd(prod){
		prod = trim(prod);
		var tab_prod = prod.split('|');

		var listProduit = tab_prod[0];
		var listColor = tab_prod[1];

		if(listProduit != "" && listColor != "")
			window.location = BBVars.pagesURL + "liste_produit.cfm?list_prod="+ listProduit + "&list_attrib=" + listColor + "&type=produitsVus";
}
function voirListProduit() {
	$.get(BBVars.pageURL+"ajax/liste_produits_vus.cfm?getList=1&type=produitsVus",
			function(data) {afficheListProd(data);})
			 

}
/* Add product to wishlist */
function addToWishlist(formulaire, salelist) {
	if (! salelist)
		salelist=0;
	try {
		var the_form 				= jQuery("#"+formulaire);
		produit_id 	= the_form.attr("prodID");
		color_selected_id = the_form.attr("colorID");
		type_vente = jQuery("#"+formulaire+" input[name='type_vente']").val() ;
		//var the_form = document.forms[formulaire]; 
		var quantite_souhaitee = 1;
		if (salelist == 1)
		{
			quantite_souhaitee = jQuery("#"+formulaire+" input[name='quantite_souhaitee']").val() ;
			if ( quantite_souhaitee > 2)
			 { 
			 opaceIt($('popupWishlistError'), 1);
			 return;
			 }
		}
		jQuery("#"+formulaire+" input[name='salelist']").val(salelist);
		$.get(
				BBVars.pagesURL	+ "utils/addToWishlist.cfm?is_xml=true&frmaction=add_whishlist"
								+ "&produit_id=" + produit_id
								+ "&attribut_detail_id=" + color_selected_id
								+ "&type_vente=" + type_vente,
				function(data) {BBTool_openMsgBox(data, true);}
			)
		
	}
	catch (e) {
		jQuery("#"+formulaire+" input[name='frmaction']").val('add_whishlist');
		jQuery("#"+formulaire).submit();
	}
}
/* feed last seen products div with HTML*/
function getLastSeenProducts()
{
		$.get(
			BBVars.pageURL+"ajax/liste_produits_vus.cfm",
			function(data) {BBTool_openMsgBox(data, true);},
			"html"
		)
		//only if the div exists on the current page 
		
}
function updateLastSeenProducts(produit_id, colorid)
{
				
	//only if the div exists on the current page 
			$.get(
					BBVars.pageURL+"ajax/liste_produits_vus.cfm?produit_id="+produit_id+"&color_id="+colorid+"&action=add",
					function(data) {BBTool_openMsgBox(data, true);})
	//URL = BBVars.pageURL+"ajax/liste_produits_vus.cfm?produit_id="+produit_id+"&color_id="+colorid+"&action=add";
	//ColdFusion.navigate(URL,'',mycallBack,myerrorhandler);
}


function NumberFormat(nStr){
	nStr += '';
	x = nStr.split(',');
	x1 = x[0];
	x2 = x.length > 1 ? ',' + x[1] : '';
	var rgx = /(\d+)(\d{3})/;
	while (rgx.test(x1)) {
		x1 = x1.replace(rgx, '$1' + ' ' + '$2');
	}
	var r = x1 + "" + x2;
	return r.replace(".", ",");
}

/*-------------------- TRI PAR ATTRIBUT (UNIVERS) --------------------*/
function filterOver(menuID) {

	var menu = document.getElementById(menuID + '_layer').getElementsByTagName("ul")[0];
	if(!menu.style.display || menu.style.display == "none") menu.style.display = "block";
	else menu.style.display = "none";

}

function sortList(type, value){
	if(type =='price') {
		document.product_form.price_origine.value = value;
	} else if(type == 'number') {
		document.product_form.maxrows.value = parseInt(document.product_form.maxrows.value) + 12*value; 
	}
	else if(type == 'tri') {
		document.product_form.tri.value = value; 
	}
	document.product_form.submit();
}
/*---------------------------------------------------*/

/*-------------------- ONGLETS --------------------*/

/*------------------ DEV --------------------------*/

function BBTab_switchDsp ( tabN ) {


}

function sizeGuid() {
	$.get(
		BBVars.pagesURL + "ajax/guide_tailles.cfm",
		function(data) {BBTool_openMsgBox(data, true)}
	);
}

function makingOf() {
	$.get(
		BBVars.pagesURL + "ajax/making_of.cfm",
		function(data) {BBTool_openMsgBox(data, true)}
	);
}

/*------------------ ONGLETS POPUP GUIDE TAILLE -----------*/

function tab_dyn_sizeGuid (nb) {
	$("#tab_list_ul li").each(function(i) {
		if(nb==i) {
			$(this).removeClass();
			$(this).addClass("li_actif");
			$(this).animate({opacity:1}, function() {
				
				$("#tab_layer_"+i).css("display","block").animate({opacity:1}, function() {
					if(BBVars.isMsIE)
						this.style.removeAttribute("filter");
				});
			});
		} else {
			$(this).removeClass();
			$(this).addClass("li_none");
			$(this).animate({opacity:0.33}, function() {
				$("#tab_layer_"+i).animate({opacity:0}, function() {
					if(BBVars.isMsIE)
						this.style.removeAttribute("filter");
					$(this).css("display","none");
			
				});
			});
		}
	});
	
	BBTool_resize("#BBTool_msgBoxBody");
	
}
/*----------------------------------------------------------------*/

function setShippingMode( smID ) {

	if(typeof(smID)=="undefined") smID = jQuery("#frmModeLivraison input[name='mode_livraison']:checked").attr("value");
	else jQuery("#frmModeLivraison input[type='radio']:eq("+(smID-1)+")").attr("checked", true);
	
	if(smID==1||smID==6)
		{jQuery("#slider").activate(0);}
	else if (smID==2)
		jQuery("#slider").activate(2);
	else if (smID==5)
		jQuery("#slider").activate(3);

}


/*--------------------------------- CALLBACKS ---------------------------------*/

function BBGallery_callback() {

	BBGallery("build", "BBGallery_list");
}

var iteration = 0;

function updateLastProdList() {

	//BBTool_resize( "#lastProd_list");
	var listHeight = Math.round(jQuery("#lastProd_list li").length/3) * (jQuery("#lastProd_list li:first").height()+10) + "px";
	jQuery("#lastProd_list").animate({height: listHeight});

}

function getOptions_callback(data) {
	fInitSymbols();
	fInitCrossSymbols();
	BBVars.currentProdQty = 1;
	var firstAvailableOption = $(".sizesList option[stock!=0]").eq(0);
		firstAvailableOption.attr("selected", "selected");
	BBCart('setAttrib', firstAvailableOption.attr("id"),1,'', setAttrib_callBack);
}

function setAttrib_callBack(data) {

	/*$(".sizesList[prodID="+BBVars.currentProdID+"] option").each(function() {
		if($(this).attr("optionID")==BBVars.currentOptionID) $(this).addClass("selected");
		else $(this).removeClass();
	});*/
	
	//$(this).addClass("selected", $(this).attr("ref")==BBVars.currentProdEAN);
	/*alert(currentAttribIndex);
	if(currentAttribIndex!=-1) $("#sizesList li#item"+currentAttribIndex).addClass("selected");*/

}

function checkClient_callback(data) {}
function checkClient() {
	$.get(
		BBVars.pagesURL + "ajax/login.cfm?formAction=checkClient",
		function(data) {BBTool_openMsgBox(data, true)},
		"html"
	);
}

function login_callback(data) {setTimeout("BBTool_closeMsgBox()",2000);}
function BBLogin() {
	$.get(
		BBVars.pagesURL + "ajax/login.cfm?formAction=prompt",
		function(data) {BBTool_openMsgBox(data, true)}
	);
}

function sendPwd_callback(data) {setTimeout("BBTool_closeMsgBox()",2000);}
function sendPwd() {
	$.get(
		BBVars.pagesURL + "ajax/login.cfm?formAction=promptPwd",
		function(data) {BBTool_openMsgBox(data, true)}
	);
}

/* on continue les achats et on envoi sur cross selling*/
function continuerAchat(){

	/*var listProduitCross = "";
	var listColorCross = "";
	

	for(i=0;i< listTypeCross.length;i++){
		if($("#list_prod_" + i).length > 0) listProduitCross =  (listProduitCross != "")? listProduitCross + ","  + $("#list_prod_" + i).val() : $("#list_prod_" + i).val() ;
		if($("#list_atrib_" + i).length > 0) listColorCross =   (listColorCross != "")? listColorCross + "," + $("#list_atrib_" + i).val(): $("#list_atrib_" + i).val();
		if($("#list_prod_" + i+ "cross").length > 0) listProduitCross =  (listProduitCross != "")? listProduitCross + ","  + $("#list_prod_" + i+ "cross").val() : $("#list_prod_" + i+ "cross").val() ;
		if($("#list_atrib_" + i+ "cross").length > 0) listColorCross = (listColorCross != "")? listColorCross + "," + $("#list_atrib_" + i+ "cross").val(): $("#list_atrib_" + i+ "cross").val();
	}
	if(listProduitCross != "" && listColorCross != "")
		window.location=BBVars.pagesURL + "crossselling.cfm?list_produit_cross="+ listProduitCross + "&list_attrib_cross=" + listColorCross;
	else BBTool_closeMsgBox();*/
	
	var listProduitCross = "";
	var listColorCross = "";
	for(i=0;i< listTypeCross.length;i++) {
		if($("#list_prod_" + i)){
			if($("#list_prod_" + i).length > 0)
				listProduitCross = (listProduitCross != "")
					? listProduitCross + ","  + $("#list_prod_" + i).val()
					: $("#list_prod_" + i).val() ;
					
			if($("#list_atrib_" + i).length > 0)
				listColorCross = (listColorCross != "")
					? listColorCross + "," + $("#list_atrib_" + i).val()
					: $("#list_atrib_" + i).val();
		}	
		if($("#list_prod_" + i+ "cross")){
			if($("#list_prod_" + i+ "cross").length > 0)
				listProduitCross =  (listProduitCross != "")
					? listProduitCross + ","  + $("#list_prod_" + i+ "cross").val()
					: $("#list_prod_" + i+ "cross").val() ;
					
			if($("#list_atrib_" + i+ "cross").length > 0)
				listColorCross = (listColorCross != "")
					? listColorCross + "," + $("#list_atrib_" + i+ "cross").val()
					: $("#list_atrib_" + i+ "cross").val();
		}	
	}
	
	if(listProduitCross != "" && listColorCross != "")
		window.location = BBVars.pagesURL + "liste_produit.cfm?list_prod="+ listProduitCross + "&list_attrib=" + listColorCross;
	else BBTool_closeMsgBox();

}
/* Affiche le cross sellling*/

function showCross(prodID,colorID){
	//MagicZoom.stop(document.getElementById("imagePRoduit"));
	$.get(
		BBVars.pagesURL + "fiche_cross.cfm?produit_id=" + prodID + "&coul_att_detailID=" +colorID ,
		function(data) {BBTool_openMsgBox(data, true)}
	);
	
}

function newAccountCallback( error ) {

	jQuery("#new_account_form").attr("check", 
			(jQuery("#new_account_form .error").length>0) ? false : true
	)
	
	var dspError = !(jQuery("#new_account_form").attr("check")=="true") ? true : false;

	if(dspError) jQuery("#btn_layer div.next_btn").BBFadeOut();
	else jQuery("#btn_layer div.next_btn").BBFadeIn();
	
}

function initDebug() {

	//alert(jQuery("#debugLayer code").length);
	jQuery("#debugLayer").css({position: "absolute", top: 0, left: 0});
	jQuery("#debugLayer code").each( function(i,d) {
	
		jQuery(this).click( function() { 
				(jQuery(this).next().next().css("display")=="none")
						? jQuery(this).next().next().slideDown()
						: jQuery(this).next().next().slideUp();
				})
			.next().next().slideUp()
	
	});

}

/*
function initConcours() {
	jQuery("#BBTool_msgBoxHeader").css("display","none");
	jQuery("#concours_layer").html('<iframe height="460" width="790" id="concours" src="http://www.jeuscottage.groupe-beaumanoir.info/lejeu.html" scrolling=no frameborder=0 > </iframe>');

}
*/

function initPromo() {
	//BBSettings.BBPopup.elementsSettings.width = "790px";
	//BBSettings.BBPopup.elementsSettings.height = "460px";
	
	$.get(
		BBVars.pagesURL + "ajax/promo.cfm",
		function(data) {BBTool_openMsgBox(data, true);}
	);
	
}

/*--------------------------------- INIT FUNCTIONS ---------------------------------*/

$(document).ready(function() {
	
	
	if(BBVars.currentPageName!="paiement") {
		checkClient();
		BBCart("check");
		BBTool_flash();
	}
	
	//initMenu();
	//initDebug();
	BBTool_initRTForms();
	getLastSeenProducts();
	fInitSymbols();
	BBTool_toolTip();
	
	var BBTool_pageSizes 			= BBTool_getPageSize();
	var BBTool_pageScroll 			= BBTool_getPageScroll();
	
		BBVars.pageWidth 			= BBTool_pageSizes[0];
		BBVars.pageHeight 			= BBTool_pageSizes[1];
		BBVars.windowWidth 			= BBTool_pageSizes[2];
		BBVars.windowHeight 		= BBTool_pageSizes[3];
		BBVars.pageScrollX 			= BBTool_pageScroll[0];
		BBVars.pageScrollY 			= BBTool_pageScroll[1];
		
		BBVars.dataSendContentID	= ($(".dataSend").length>0) ? $(".dataSend").attr("id") : "";
	
	if(BBVars.currentPageName=="univers" || BBVars.currentPageName=="selection") {
	
		var itemList = jQuery("#products_list li");
		
		itemList.each( function(i,el) {
			var cont = jQuery(this),
				link = jQuery("a.jqzoom", cont),
				img = jQuery("img.prodImg", link),
				width = img.width();
			if(width>218) {
				cont.css({position: "relative"});
				link.css({overflow: "hidden"});
				img.css({position: "relative", left: "-44px"});
				
				var leftPos = -47;
				if((i%3)==0) leftPos = -3;
				else if((i%3)==2) leftPos = -112;
				
				cont.bind("mouseenter", function(e) {
					cont.append( jQuery("<div class='zoomImg'><img src='"+img.attr("src")+"'></div>")
									.css({
										position: "absolute",
										left: leftPos,
										top: "-3px",
										zIndex: 100,
										cursor: "pointer"
									}).bind("click", function() { window.location = link.attr("href"); })
								);
					cont.append( jQuery(".prodPicto", link).clone().css({left: leftPos+3, zIndex: 10000, cursor: "pointer"}).addClass("cloned").bind("click", function() { window.location = link.attr("href"); }) );
				}).bind("mouseleave", function(e) {
					jQuery(".zoomImg", this).remove();
					jQuery(".cloned", this).remove();
				});
			}
		});
	
	} else if(BBVars.currentPageName=="index") {
	
		initPromo();
	
		jQuery("#HomeRightTop_banner a")
				.css({opacity: 0, display: "none"})
				.attr("rel","false");
		jQuery("#HomeRightTop_banner a").eq(0)
				.css("display","block")
				.attr("rel","true")
				.animate({opacity: 1}, function() {
						if(jQuery("#HomeRightTop_banner a").length>1) setInterval("showBanner()",4000);
					});
/*AJOUT PAR BENOIT B - TICKET 5930*/
/*
		jQuery("#HomeRightBot_banner a")
				.css({opacity: 0, display: "none"})
				.attr("rel","false");
		jQuery("#HomeRightBot_banner a").eq(0)
				.css("display","block")
				.attr("rel","true")
				.animate({opacity: 1}, function() {
						setInterval("showBannerBottom()",4000);
					});
*/
		jQuery("#center_col a")
				.css({opacity: 0, display: "none"})
				.attr("rel","false");
		jQuery("#center_col a").eq(0)
				.css("display","block")
				.attr("rel","true")
				.animate({opacity: 1}, function() {
						if(jQuery("#center_col a").length>1) setInterval("showBannerCenter()",5000);
					});
/**/
		
		BBSettings.BBPopup.elementsSettings.width = "790px";
		BBSettings.BBPopup.elementsSettings.height = "460px";
		/*$.get( BBVars.pagesURL + "ajax/concours.cfm", function(data) {
				
				BBTool_openMsgBox(data, true)
			});*/
		
	} else if(BBVars.currentPageName=="fiche") {
		
		updateLastSeenProducts(ref_produitid_lastseen,ref_color_lastseen);
		//BBGallery("build", "gallery");
		//BBCart("getOptions");
		/*if(typeof(fiche_mode) != undefined)
			BBCart("getOptions","item"+$("#product_form" + fiche_mode+" input[name='produit_id']").val());*/
		//tab_dyn_fiche(0);
		
		jQuery("#gallery .BBTool_galMainImg").bind("mouseenter", function() {
			jQuery(".prodPicto", this).css("display", "none");
			jQuery("body").bind("mousemove", function(e) {
				if(e.pageX<jQuery("#gallery .BBTool_galMainImg").offset().left||e.pageX>jQuery("#gallery .BBTool_galMainImg").offset().left+326||e.pageY<jQuery("#gallery .BBTool_galMainImg").offset().top||e.pageY>jQuery("#gallery .BBTool_galMainImg").offset().top+326) {
					jQuery(".prodPicto", this).css("display", "block");
					jQuery("body").unbind("mousemove");
				}
			});
		})
	} else if(BBVars.currentPageName=="panier") {
		
		hideDelivery();
		
	} else if(BBVars.currentPageName=="livraison") {
		var options = {
			header:			'strong', 
			autoheight:		false
		}
		$("#slider").accordion(options);
		setShippingMode();
		//if(BBVars.adrType!=0) $("#slider").activate((BBVars.adrType-1));
		
	} else if(BBVars.currentPageName=="faq") {
		var options = {
			header:			'strong', 
			autoheight:		false,
			active: 		false
		}
		$("#faq_slider").accordion(options);
	
	} else if(BBVars.currentPageName=="magasins") {
		var options = {
			header:			'strong', 
	        autoheight: 	false,
	        alwaysOpen: 	false,
	        active: 		false
		}
		$("#lastOpened").accordion(options).activate(-1);
	}
});

/*----------------------------------------------------------------------------------*/

function showBanner() {

	jQuery("#HomeRightTop_banner a[rel='true']").animate({opacity:0}, function() {
		jQuery(this).css("display","none").attr("rel","false");
		var nextLayer = (jQuery(this).next().hasClass("rightTopBanner")) ? jQuery(this).next() : jQuery("#HomeRightTop_banner a").eq(0);
		nextLayer.css("display","block").attr("rel","true").animate({opacity: 1}, function() {});
	});

}
/*AJOUT PAR BENOIT B - TICKET 5930*/	
function showBannerBottom() {

	jQuery("#HomeRightBot_banner a[rel='true']").animate({opacity:0}, function() {
		jQuery(this).css("display","none").attr("rel","false");
		var nextLayer = (jQuery(this).next().hasClass("rightBotBanner")) ? jQuery(this).next() : jQuery("#HomeRightBot_banner a").eq(0);
		nextLayer.css("display","block").attr("rel","true").animate({opacity: 1}, function() {});
	});

}

function showBannerCenter() {

	jQuery("#center_col a[rel='true']").animate({opacity:0}, function() {
		jQuery(this).css("display","none").attr("rel","false");
		var nextLayer = (jQuery(this).next().hasClass("homeCenterBanner")) ? jQuery(this).next() : jQuery("#center_col a").eq(0);
		nextLayer.css("display","block").attr("rel","true").animate({opacity: 1}, function() {});
	});

}
/**/

function fInitSymbols() {
	jQuery("#symbolsList li").each( function(i) {
		jQuery(this).bind( "mouseenter", function(e) {
			jQuery("#alertSymbols").css("background-position", -28-27*(4-i) +"px 100%");
			jQuery("#alertSymbols").html(jQuery(this).html());
		});
	});

}

function fInitCrossSymbols() {
	jQuery("#symbolsListcross li").each( function(i) {
		jQuery(this).bind( "mouseenter", function(e) {
			jQuery("#alertSymbolscross").css("background-position", -28-27*(4-i) +"px 100%");
			jQuery("#alertSymbolscross").html(jQuery(this).html());
		});
	});

}

/*--------------------------------------------------------------------*/
// silhouettes

var selectHover = false;
var selectOpened = false;

function openSelect() {

	if($("#silBlock_list").attr("display") != "block") {
		$("#silBlock_list").css("display","block");
		selectOpened = true;
	}
	

}

function closeSelect() {

	$("#silBlock_list").css("display","none");
	selectOpened = false;

}

function showZoom(dsp) {

	if(dsp) $("#silZoomLayer").BBFadeIn().css("display","block");
	else $("#silZoomLayer").BBFadeOut().css("display","none");

}


function viewDefil(videoSrc,action) {
	
	/*var dsp = ($("#view_defil").css("display")=="none"||$("#view_defil").css("display")==undefined) ? "block" : "none";
	$("#view_defil").css("display",dsp);
	var dsp = ($("#view_sil").css("display")=="none"||$("#view_sil").css("display")==undefined) ? "block" : "none";
	$("#view_sil").css("display", dsp);*/
		
	//$('#imgDspLayer').html("");
	
	if(action) {
	
		$('#styleVideoBtn').animate({opacity: 0}, function() {
			$('#styleImgBtn').css({opacity: 0, display: "block"}).animate({opacity: 1}, function() {
				if(BBVars.isMsIE) jQuery(this).css({opacity: 1, filter: "none"});
			});
		});
		$('#imgDspLayer #img').animate({opacity: 0}, function() {
			$('#imgDspLayer #flashLayer')
				.css({display: "block", opacity: 0})
				.flash({
					src: BBVars.pagesURL + 'ximg/flash/player.swf',
					width: 240,
					height: 420,
					wmode: 'transparent',
					allowScriptAccess: 'always',
					salign: 'tl',
					align: 'top',
					flashvars: {
						flvwidth: 640,
						flvheight: 1120,
						flvname: videoSrc
					}
				})
				.animate({opacity: 1});
		});
	
	} else {
	
		$('#styleImgBtn').animate({opacity: 0}, function() {
			$(this).css("display","none");
			$('#styleVideoBtn').animate({opacity: 1});
		});
		$('#imgDspLayer #flashLayer').animate({opacity: 0}, function() {
			$('#imgDspLayer #img').animate({opacity: 1});
		});
	
	}
	
}

/*---------------------------------------------------------------------------*/

function hideDelivery() {
	
/*	jQuery("#delivery").val(jQuery("#freeDelivery").attr('checked'));
	
	if (jQuery("#freeDelivery").attr('checked')) {

		jQuery("#totalFDP").hide();
		jQuery("#totalSFDP").show();

		jQuery("#delivery_case").css({overflow: "hidden", height: "50px"});
		jQuery("#delivery_case td").animate({opacity:0, borderTopWidth: 0,borderRightWidth: 0,borderLeftWidth: 0,borderBottomWidth: 0, lineHeight: 0}, function() {
				jQuery("*",this).css({display: "none", height: 0});
				jQuery("#delivery_case").animate({height: 0});
			});

	} else {

		jQuery("#delivery_case").animate({height: "50px"}, function() {
			jQuery("td *",this).css({display: "block"});
			jQuery("td", this).animate({opacity: 1, borderRightWidth: "2px", borderTopWidth: "5px", lineHeight: "14px"});
		});

		jQuery("#totalFDP").show();
		jQuery("#totalSFDP").hide();
		
	}*/
}

function hideBtnFinishOrder() {
	
	if (jQuery("#accepte_cgv").attr('checked')) {
	
		jQuery(".no_click_btn").css({display: "none", opacity: "0"});
		jQuery(".continueShop_btn").css({display: "block", opacity: "1"});
		jQuery("#finishOrderOff").val(true);
	
	} else {
	
		jQuery(".no_click_btn").css({display: "block", opacity: "1"});
		jQuery(".continueShop_btn").css({display: "none", opacity: "0"});
		jQuery("#finishOrderOff").val(false);
		
	}
}

function comparerID(page) {
	//alert('1');
	document.forms['product_form'].elements['page'].value = page;
	if(document.location) document.forms['product_form'].action = document.location;
	document.forms['product_form'].submit();
}

function valid_form() {

	document.forms['product_form'].submit();	
	
}

function reloadForm(maxrows) {
	document.forms['product_form'].elements['maxrows'].value = maxrows;
	document.forms['product_form'].submit();
}

function CFNavigate_error() {}
function CFNavigate_callBack() {}


function recherchePointRelais(){
	$.get(
		BBVars.pagesURL + "ajax/liste_mondial_relay.cfm?pays=" + document.frmMondial.pays.value + "&ville_mondial_relay=" + document.frmMondial.ville_mondial.value + 
			"&cp_mondial_relay=" + document.frmMondial.mr_cp.value+ "&adresse_mondial_relay=" + document.frmMondial.adresse1_mondial.value + 
			"&kiala_point_id=" + document.frmMondial.kiala_cp_point.value,
		function(data) {setListeMondialRelay(data)}
	);
}

function setListeMondialRelay (liste) {
	jQuery("#liste_mondial_relay").html(liste);initOpHours();
}

function initOpHours() {
		
		jQuery(".resultats").tooltip(function (el) {
			return jQuery(el).attr("list")
			}, {
			'tooltipID': BBSettings.defaultTTipName,
			'tTipHeight': 60,
			'tTipWidth': 60
		});
	
}
