function check_and_go() { //firma -- text //imie -- text if( document.kontakt['kontakt[imie]'].value == '' ) { alert( 'pole \'Imię\' jest wymagane' ) ; return ; } //nazwisko -- text if( document.kontakt['kontakt[nazwisko]'].value == '' ) { alert( 'pole \'Nazwisko\' jest wymagane' ) ; return ; } //email -- text //telefon -- text //sposob_kontaktu -- checkbox if( document.kontakt['kontakt[sposob_kontaktu][Telefon]'].checked == false && document.kontakt['kontakt[sposob_kontaktu][Email]'].checked == false ) { alert( 'pole \'Jak mamy się z Tobą skontaktować\' jest wymagane' ) ; return ; } //tresc -- textarea if( document.kontakt['kontakt[tresc]'].value == '' ) { alert( 'pole \'Treść wiadomości\' jest wymagane' ) ; return ; } document.kontakt.submit() }