
function checkForm() {
	with (document.forms['kontakt']) {
		var alertMsg = "Wypełnij poniższe pola:\n";

		if ((k_email.value =="Twój adres e-mail") || (k_email.value == "") || (k_email.value.indexOf ('@') == -1) || (k_email.value.indexOf ('.') == -1)) alertMsg += "\nTwój email";
		if ((k_kod.value == "") ) alertMsg += "\nKod";
		if ((k_tresc.value == "")) alertMsg += "\nwiadomość";
	}

	

	if (alertMsg != "Wypełnij poniższe pola:\n") {
		alert(alertMsg);
		return false;
	} else {
		return true;
	}

}



function checkFormQuestion() {
	with (document.forms['szukaj']) {
		var alertMsg = "Wypełnij poniższe pola:\n";

		if ((f_email.value =="Twój adres e-mail") || (f_email.value == "") || (f_email.value.indexOf ('@') == -1) || (k_email.value.indexOf ('.') == -1)) alertMsg += "\ne-mail";
		if ((f_firma.value == "") ) alertMsg += "\nfirma";
		if ((f_imie.value == "")) alertMsg += "\nimię i nazwisko";
		if ((f_tel.value == "") ) alertMsg += "\ntel. kontaktowy";
		if ((f_miasto.value == "") ) alertMsg += "\nmiasto";
		if ((f_cena.value == "") ) alertMsg += "\ncena do";
		if ((f_kod.value == "") ) alertMsg += "\nkod";
	}

	

	if (alertMsg != "Wypełnij poniższe pola:\n") {
		alert(alertMsg);
		return false;
	} else {
		return true;
	}

}
