function apriSegnala() {
	sliderSegnala.toggle()	
} 

function aggiungiPreferiti(title, url) {
	if (window.sidebar) { // Mozilla Firefox Bookmark
		window.sidebar.addPanel(title, url,"");
	} else if( window.external ) { // IE Favorite
		window.external.AddFavorite( url, title); }
	else if(window.opera && window.print) { // Opera Hotlist
		return true; 
	}
}

function showEle(ele) { // elemento da mostrare
	document.getElementById(ele).style.visibility = "visible";
	document.getElementById(ele).style.display = "block";
}

function hideEle(ele) { // elemento da nascondere
	document.getElementById(ele).style.visibility = "hidden";
	document.getElementById(ele).style.display = "none";
}

function mostra(liv) {
	lv = document.getElementById(liv);
	bt = document.getElementById('but-'+liv);
	bt.className = "but-cerca-corrente";
	var livelli = ['box-ricerca-dormire', 'box-ricerca-mangiare', 'box-ricerca-altro']; // le 3 ricerche
	for (var i = 0; i < livelli.length; i++) {
		b = document.getElementById([livelli[i]]);
		//alert('b:'+b +'lv: '+lv);
		if (b.id == lv.id) {
			showEle(liv)
		} else {
			bt = document.getElementById('but-'+livelli[i]);
			bt.className = "but-cerca";
			hideEle(livelli[i])
		}
	}
}

function openWin(content,w,h,s) { //pagina, larghezza, altezza, scroll
	finestra=window.open(content,'zoom','scrollbars=' + s + ',resizable=no,width=' + w + ',height=' + h + ',status=no,location=no,toolbar=no');
	finestra.focus();
}

/* popup fluidbook */
function openFullWindow(url) {
	// parameters:	url = URL of the popup window
	//alert(screen.width);
	var w = screen.width; //fixed width
	var h = screen.height; //fixed height
	//var url = url_full;
	//if(w <= 800) {
	//	url = url_800;
	//}
	leftPosition = 0;		// centering horizontal position to middle of screen
	topPosition = 0;	// centering vertical position to middle of screen
	if (h<800)
	{
		var windowprops = 'width=' + w + ',height=' + h + ',top='+ topPosition +',left='+ leftPosition +',toolbar=no,location=no,directories=no,status=no,scrollbars=yes,menubar=no'; //set popup window properties
	} else
	{
		var windowprops = 'width=' + w + ',height=' + h + ',top='+ topPosition +',left='+ leftPosition +',toolbar=no,location=no,directories=no,status=no,scrollbars=yes,menubar=no'; //set popup window properties
	}
	var popup = window.open(url,'remote',windowprops); // open popup window with properties
	popup.moveTo(0,0)
	popup.resizeTo(screen.width,screen.height);
	popup.focus(); // focus on window
}

function catalogo_2011()
{
 			openFullWindow("http://fluidbook.it/book/larivieradellepalme/catalogo2011/");
}

function listino_2011()
{
 			openFullWindow("http://fluidbook.it/book/larivieradellepalme/listino2011/");
}
//-->

