function CheckSellForm(){ var paymentSelected = false; var i; for(i=0; i<=4; i++){ if(document.getElementById('payMode_' + i).checked){ paymentSelected = true; break; } } if(!paymentSelected){ alert('Devi selezionare almeno un metodo con cui accettare gli eventuali pagamenti'); return false; } if(document.getElementById('termsandconditions').checked){ return true; }else{ alert('Devi dichiarare di aver letto e di accettare i termini e le condizioni del servizio'); return false; } } function CheckMakeOfferForm(){ if(document.getElementById('termsandconditions').checked){ return true; }else{ alert('Devi dichiarare di aver letto e di accettare i termini e le condizioni del servizio'); return false; } } function CheckRegForm() { var thisForm = document.forms['regForm']; var company = thisForm.company.value; var street = thisForm.street.value; var city = thisForm.city.value; var prov = thisForm.prov.value; var zipcode = thisForm.zipcode.value; var vatnumber = thisForm.vatnumber.value; if((company == "") || (company == "undefined")) { alert("Il campo Ragione Sociale è obbligatorio."); thisForm.company.focus(); return false; } if((street == "") || (street == "undefined")) { alert("Il campo Via e civico è obbligatorio."); thisForm.street.focus(); return false; } if((zipcode == "") || (zipcode == "undefined")) { alert("Il campo CAP è obbligatorio."); thisForm.zipcode.focus(); return false; } if((city == "") || (city == "undefined")) { alert("Il campo città è obbligatorio."); thisForm.city.focus(); return false; } if((prov == "") || (prov == "undefined")) { alert("Il campo Provincia è obbligatorio."); thisForm.prov.focus(); return false; } if((vatnumber == "") || (vatnumber == "undefined")){ alert("Il campo P.IVA è obbligatorio e deve contenere un numero di partita IVA valido."); thisForm.vatnumber.focus(); return false; } }