//$(document).ready(function() {
//	
//	$("#lin_5").click(function(){
			
//			$.ajax({	 
//				url: "ajax/file_cat.php?cat="+vi,
//				cache: false,
//				success: function(html){
//				$("#nasco_cat_5").empty();	
//				$("#nasco_cat_5").append(html);
//  			}
//		});
//	});
//
//});

$(document).ready(function() {
	$('#center').corner({
		  tl: { radius: 1 },
		  tr: { radius: 1 },
		  bl: { radius: 20 },
		  br: { radius: 20 },
		  antiAlias: true});
	$(".copy_sun").corner("");

});


function formCheck(thisForm){
	 if(thisForm.nome.value=='') {
		window.alert('Inserire un nome');
		thisForm.nome.focus();
		return false;
	 }
	 if( thisForm.email.value=='' || ( thisForm.email.value.indexOf('@',0) == -1) || (thisForm.email.value=='@')){
		window.alert('Inserire un in indirizzo email corretto');
		thisForm.email.focus();
		return false;
	 }
	  if(thisForm.indirizzo.value=='') {
		window.alert('Inserire un indirizzo');
		thisForm.indirizzo.focus();
		return false;
	 } 
    if(thisForm.richiesta.value=='') {
		window.alert('Inserire una richiesta');
		thisForm.richiesta.focus();
		return false;
	 }
	 if (!thisForm.noyes[1].checked) {
		window.alert('Non sono state accettate le condizioni per la privacy');
		thisForm.AccPrivacy[1].focus();
		return false;
	 }  
	 else{
	 	document.formOne.submit();
	 }
    
}


function ajxUpd(val){
	var name='#nasco_cat_'+val;
		$.ajax({	 
			url: "../ajax/file_cat.php?cat="+val,
			cache: false,
			success: function(html){
				$(name).empty();	
				$(name).append(html);
				$(name).slideToggle("slow");
			}
		});
	
}

function ajxUpdS(val){
	var name='#so_cat_'+val;
	$.ajax({	 
		url: "../ajax/file_cat.php?scat="+val,
		cache: false,
		success: function(html){
			$(name).empty();	
			$(name).append(html);
			$(name).slideToggle("slow");
		}
	});
	
}


function ajxUpdPro(val){
	var name='.right_col';
	$(name).empty();
	$("#pascosto").show();
	$.ajax({	 
		url: "../ajax/file_cat.php?prod="+val,
		cache: false,
		success: function(html){
			$("#pascosto").hide();
			$(name).fadeIn(500);
			$(name).empty();	
			$(name).append(html);
			
		}
	});
	
}

function ajxUpdDotto(val){
	var name='.right_col';
	$(name).empty();
	$("#pascosto").show();
	$.ajax({	 
		url: "../ajax/file_cat.php?dotto="+val,
		cache: false,
		success: function(html){
			$("#pascosto").hide();
			$(name).fadeIn(500);
			$(name).empty();	
			$(name).append(html);
			
		}
	});
	
}

