function hide_block(str) {
	document.getElementById(str).style.display = "none";
}
function display_block(str) {
	document.getElementById(str).style.display = "block";
}
function MM_jumpMenu(targ,selObj,restore){ //v3.0
  eval(targ+".location='"+selObj.options[selObj.selectedIndex].value+"'");
  if (restore) selObj.selectedIndex=0;
}
function button_eventi(val){
	document.form_head_eve.eve_tipo.value=val;
	document.form_head_eve.submit();
}

function lancia_ricerca_alloggio(action,post){
	if(!post)
	  document.form_cerca_alloggio.mem_sel_cerca_alloggio.value="";
	else{
	  valore=document.form_cerca_alloggio.mem_sel_cerca_alloggio.value;
	  if(valore.indexOf(post)=="-1")
	    document.form_cerca_alloggio.mem_sel_cerca_alloggio.value=valore + post;
	  else
	    document.form_cerca_alloggio.mem_sel_cerca_alloggio.value=valore.replace(post, "");
	}
	document.getElementById('form_cerca_alloggio').action=action
	document.form_cerca_alloggio.submit();
}
function c_clk(lik){
  location.href=lik;
}
function aree_mostra_all(are_id, strlink, strcount, strnome){
  document.getElementById('are_mostra_all' + are_id).innerHTML="";
  
  var arr_strlink=strlink.split("@|"); 	 
  var arr_strcount=strcount.split("@|"); 	 
  var arr_strnome=strnome.split("@|"); 	 
  var aggiunta="";
  for (i=0; i<arr_strlink.length; i++) { 
    if(arr_strcount[i])
      aggiunta = aggiunta + "<div class=\"lista_voc2\"><h4><a href=\"" + arr_strlink[i] + ".php\">" + arr_strnome[i] + " (" + arr_strcount[i] + ")</a></h4></div>";
  }
  document.getElementById('are_mostra_all' + are_id + '_voci').innerHTML=document.getElementById('are_mostra_all' + are_id).innerHTML + aggiunta;
}
function raxsel(id){
  document.getElementById('box_rax' + id).innerHTML="<img src=\"/templates/images/v1.gif\" alt=\"sel\">";
}
function raxnsel(id){
  document.getElementById('box_rax' + id).innerHTML="";
}
function rassel(id){
  document.getElementById('box_ras' + id).innerHTML="<img src=\"/templates/images/v2.gif\" alt=\"sel\">";
}
function rasnsel(id){
  document.getElementById('box_ras' + id).innerHTML="<img src=\"/templates/images/x2.gif\" alt=\"sel\">";
}
function change_eve_tipo(id,pro_file){
	var arr_pg_eve=Array();
	if(pro_file)
	  agg_act="-" + pro_file;
	else
	  agg_act="";
	arr_pg_eve['']="eventi" + agg_act + ".php";
	arr_pg_eve[171]="gallerie_d_arte" + agg_act + ".php";
	arr_pg_eve[170]="teatri" + agg_act + ".php";
	arr_pg_eve[372]="musica-live" + agg_act + ".php";
	//if(id)
	  document.form_eventi.action=arr_pg_eve[id];
	document.form_eventi.submit();
}

