jQuery.noConflict();
function NascondiQuick () {
	jQuery("#ContRapido").hide();
	jQuery(".RapidTitolo").html("<img src='/_templates/cr-aldeno/Quardatini_button01.jpg'>&nbsp;<a href='#' class='RapidLink' onClick='vediQuick(); return false;'>ACCESSO RAPIDO</a>");

}

function vediQuick () {
	jQuery("#ContRapido").show("slow"); 
	jQuery(".RapidTitolo").html("<img src='/_templates/cr-aldeno/Freccia_Bottom01.jpg'>&nbsp;<a href='#' class='RapidLink' onClick='HideQuick(); return false;'>ACCESSO RAPIDO</a>");
}

function HideQuick () {
	jQuery("#ContRapido").hide("slow"); 
	jQuery(".RapidTitolo").html("<img src='/_templates/cr-aldeno/Quardatini_button01.jpg'>&nbsp;<a href='#' class='RapidLink' onClick='vediQuick(); return false;'>ACCESSO RAPIDO</a>");
}

function Expand (objid) {
	jQuery("#"+objid).show("slow");
	
	  jQuery("#img"+objid).html("<img src='/_templates/cr-aldeno/Ikona_piu.jpg' onClick='Implode("+objid+")'  />");


}

function Implode (objid) {
	jQuery("#"+objid).hide("slow");
	
	  jQuery("#img"+objid).html("<img src='/_templates/cr-aldeno/Ikona_meno.jpg'' onClick='Expand("+objid+")'  />");
}



function altezzaDiv (elmID) {
if(document.getElementById(elmID).clientHeight) {
return document.getElementById(elmID).clientHeight;
}
else {
if(document.getElementById(elmID).offsetHeight) {
return document.getElementById(elmID).offsetHeight;
}
}
}

function setHeight (cosa,altezza) {
	document.getElementById(cosa).style.height = altezza+'px';

}
	
	
function fai() {
	if(document.body.clientHeight) {
		alt = document.body.clientHeight;
	}
	else {
		if (window.innerHeight) {
			alt = window.innerHeight;
		}
	}
	


	var variazione = alt-428;
	jQuery("#Navigation").css( "height", variazione+"px" );


}

function RegolaLaterale() {
	altmenu = altezzaDiv('Navigation');
	jQuery('#AccessoRapido').css("height", altmenu+"px");
	jQuery('#ContRapido').css("height", (altmenu-22)+"px");
}


function Nascondi (id_el) {
	jQuery("#"+id_el).hide();
}
var active3;
function show3Liv (id_el) {
	if (active3) {
		jQuery("#"+active3).hide();
	}
	if(jQuery("#"+id_el)) {
		jQuery("#"+id_el).show();
	}
	active3 = id_el;
}

function LinksTop(id_img) {
	switch(id_img) {
		case "mappa":
		jQuery("#mappa").attr({ 
          src: "/_templates/piaceredimela/sitomapa_mela.gif"
        });
		jQuery("#LinkTop").html('<a href="/italian/mappa_del_sito.php" title="Questo collegamento conduce alla mappa del sito piaceredimela.it">Mappa del sito</a>');
		break;
		case "cerca":
		jQuery("#cerca").attr({ 
          src: "/_templates/piaceredimela/cerca_mela.gif"
        });
		jQuery("#LinkTop").html('<a href="/italian/cerca.php" title="Questo collegamento conduce alla pagina di ricerca">Cerca nel sito</a>');
		break;
		case "photogallery":
		jQuery("#photogallery").attr({ 
          src: "/_templates/piaceredimela/foto_mela.gif"
        });
		jQuery("#LinkTop").html('<a href="/italian/photogallery.php" title="Questo collegamento conduce alla pagina della photogallery">Photogallery</a>');
		break;
	}
}

window.onload=function(){
	var mela1 = new Image();
	var mela2 = new Image();
	var mela3 = new Image();
	mela1.src= "/_templates/piaceredimela/foto_mela.gif";
	mela2.src= "/_templates/piaceredimela/cerca_mela.gif";
	mela3.src= "/_templates/piaceredimela/sitomapa_mela.gif";
	} 
function ReImageTop(id_img) {
	switch(id_img) {
		case "mappa":
		jQuery("#mappa").attr({ 
          src: "/_templates/piaceredimela/sitomapa_bolo.gif"
        });
		jQuery("#LinkTop").html('');
		break;
		case "cerca":
		jQuery("#cerca").attr({ 
          src: "/_templates/piaceredimela/cerca_bolo.gif"
        });
		jQuery("#LinkTop").html('');
		break;
		case "photogallery":
		jQuery("#photogallery").attr({ 
          src: "/_templates/piaceredimela/foto_bolo.gif"
        });
		jQuery("#LinkTop").html('');
		break;
	}
}

function scriviintro() {
document.write('<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=7,0,19,0" width="1117" height="315"><param name="movie" value="/_media/images/mela_michele.swf"><param name="quality" value="high"><embed src="/_media/images/mela_michele.swf" quality="high" pluginspage="http://www.macromedia.com/go/getflashplayer" type="application/x-shockwave-flash" width="1117" height="315"></embed></object>');
}