function CheckMultiple1(frm, name) {
		for (var i=0; i < frm.length; i++)
		{
			fldObj = frm.elements[i];
			fldId = fldObj.id;
			if (fldId) {
				var fieldnamecheck=fldObj.id.indexOf(name);
				if (fieldnamecheck != -1) {
					if (fldObj.checked) {
						return true;
					}
				}
			}
		}
		return false;
	}


function CheckForm1(f) {
	if (f.email.value == "") {
		alert("Per favore inserire il proprio indirizzo e-mail.");
		f.email.focus();
		return false;
	}

if (f.format.selectedIndex == -1) {
					alert("Per favore scegliere un formato con il quale ricevere una campagna e-mail");
					f.format.focus();
					return false;
				}
			
		return true;
	};

 function setForm() {
  tmp = new Date();
  oggi = pad2(tmp.getDate()) + "-" + pad2(tmp.getMonth()+1) + "-" + tmp.getFullYear();
  tmp = new Date(tmp.getTime()+86400000);
  domani = pad2(tmp.getDate()) + "-" + pad2(tmp.getMonth()+1) + "-" + tmp.getFullYear();
  document.getElementById("checkin").value = oggi;
  document.getElementById("checkout").value = domani;
 }
  
 function pad2(str) {
  if (str < 10) {
   return "0" + str;
  } else {
   return str;
  }
 }  