//BELFOOD SERVICE, Powered by BLUE ACACIA : WEB AGENCY, Créateur de liens

function favoris() {
	if ( navigator.appName != 'Microsoft Internet Explorer' ) { 
		window.sidebar.addPanel("BELFOOD SERVICE.COM","http://www.belfoodservice.com","");
	}else {
		window.external.AddFavorite("http://www.belfoodservice.com","BELFOOD SERVICE.COM");
	}
}

function setpng(img) { 
	if(document.all && (IEver=parseFloat(navigator.appVersion.split("MSIE")[1])) && (IEver>=5.5) && (IEver<7) && document.body.filters && img) {
		imgName=img.src.toUpperCase();
		if(imgName.substring(imgName.length-3,imgName.length)=="PNG") {
			img.outerHTML="<span "+(img.id?"id='"+img.id+"' ":"")+(img.className?"class='"+img.className+"' ":"")+(img.title?"title=\""+img.title+"\" ":"")+"style=\"width:"+img.width+"px;height:"+img.height+"px;"+(img.align=="left"?"float:left;":(img.align=="right"?"float:right;":""))+(img.parentElement.href?"cursor:hand;":"")+"display:inline-block;"+img.style.cssText+";"+"filter:progid:DXImageTransform.Microsoft.AlphaImageLoader(src='"+img.src+"',sizingMethod='scale');\"></span>";
		}
	}
}

function photo_afficher(image){
	var texte_image=image;
	document.photo_magasin.src='photos/magasins/photos/'+texte_image+'';
}

function savoir(d,e) {
	//alert("pouet !");
	//alert(d);
	var i;
	for (i=1;i<=e;i++) {
		document.getElementById("savoir_mode_livraison"+i).style.display = 'none';
	}
	document.getElementById(d).style.display = '';
}

function savoir_menu(d) {
	//alert("pouet !");
	//alert(d);
	if (document.getElementById(d).style.display=='') {
		document.getElementById(d).style.display='none';
	}else{
		document.getElementById(d).style.display='';
	}
}

function verifier_formulaire_afficher_article() {
	//alert("pouet !");
	//var choix=document.fomulaire_gamme.choix_gamme.value;
	//alert(choix);
	document.formulaire_afficher_article.submit();
}

function gimme_position(){             
	   var le_left=(parseInt(screen.width)-960)/2;
	   var le_top=((parseInt(screen.height)-524)/2)-120;
	   
	   if(screen.width < 960){
				//alert(document.body.offsetWidth);
				document.getElementById("content1").style.left='0px';
	   }else{
				document.getElementById("content1").style.left=le_left+'px';
	   }
	   if(screen.height < 524){
				//alert(window.innerHeight);
				document.getElementById("content1").style.height='0px';
	   }else{
				document.getElementById("content1").style.height=le_top+'px';
	   }
	//alert(le_top);   
 }
