function isEmail(string) {
 if (string.search(/^\w+((-\w+)|(\.\w+))*\@\w+((\.|-)\w+)*\.\w+$/) != -1)
  return false;
 else
 return true;
}

function check(){
 var newsletter = document.newsLetter;
 //controllo neswlwtter
 if(newsletter.email.value == "") {
  alert("Completare il campo Newsletter"); 
  newsletter.email.focus(); 
  return;
 }
 newsletter.submit();
}

function MM_openBrWindow(theURL,winName,features) { //v2.0
	window.open(theURL,winName,features);
}
function openInfo(){
	w = 400;
	h = 200;
	var winl = (screen.width-w)/2;
	var wint = (screen.height-h)/2;
	window.open("informativa.html","infowin","width=" + w + ",height=" + h + ",top=" + wint + ",left=" + winl + "");
}

/*$(document).ready(function(){	
	$("#datepicker").datepicker();

	$("#file_immagine").uploadify({
		'uploader'       : 'uploadify.swf',
		'script'         : 'uploadfile.asp',
		'cancelImg'      : 'img/cancel.png',
		'buttonText'     : 'Carica File...',
		'folder'         : '../public/',
		'auto'           : true,
		'multi'          : false,
		'wmode'          : 'transparent',
		'onComplete'     : function(a, b, c, d, e){ 
								$('#immagine').val(d);
							}
	});
});*/
