function isEmpty (str){
    strRE = new RegExp();
    strRE.compile ('^[s ]*$','gi');
    return strRE.test (str.value);
}
function notValidEmail (str) {
    mailRE = new RegExp();
    mailRE.compile ('^[._a-z0-9-]+@[.a-z0-9-]+[.]{1}[a-z]{2,4}$','gi');
    return !(mailRE.test (str.value));
}
function checkForm (form) {
    if (isEmpty (form.meno)) {
        alert ('Zadajte, prosím, vaše MENO');
        return false;
    }
	if (notValidEmail (form.email)) {
        alert ('Nezadaný alebo neplatný EMAIL');
        return false;
    }
	if (isEmpty (form.poznamka)) {
        alert ('Zadajte, prosím, TEXT SPRÁVY');
        return false;
    }
	if (isEmpty (form.number)) {
        alert ('Zadajte, prosím, OVEROVACÍ KÓD');
        return false;
    }
else {
    return true;
	}
}




function isEmpty_EN (str){
    strRE = new RegExp();
    strRE.compile ('^[s ]*$','gi');
    return strRE.test (str.value);
}
function notValidEmail_EN (str) {
    mailRE = new RegExp();
    mailRE.compile ('^[._a-z0-9-]+@[.a-z0-9-]+[.]{1}[a-z]{2,4}$','gi');
    return !(mailRE.test (str.value));
}
function checkForm_EN (form) {
    if (isEmpty (form.meno)) {
        alert ('Please enter Your Name');
        return false;
    }
	if (notValidEmail_EN (form.email)) {
        alert ('Please enter the e-mail or enter valid e-mail');
        return false;
    }
	if (isEmpty_EN (form.poznamka)) {
        alert ('Please enter Message');
        return false;
    }
	if (isEmpty_EN (form.number)) {
        alert ('Please enter the Security number');
        return false;
    }
else {
    return true;
	}
}




function C_checkForm (form) {
    if (isEmpty (form.meno)) {
        alert ('Nie je zadaná KONTAKTNÁ OSOBA !!');
        return false;
    }
	if (notValidEmail (form.email)) {
        alert ('Nezadaný alebo neplatný EMAIL !!');
        return false;
    }
	if (isEmpty (form.number)) {
        alert ('Nie je zadaný OVEROVACÍ KÓD !!');
        return false;
    }
else {
    return true;
	}
}





function M_notValidEmail (str) {
    mailRE = new RegExp();
    mailRE.compile ('^[._a-z0-9-]+@[.a-z0-9-]+[.]{1}[a-z]{2,4}$','gi');
    return !(mailRE.test (str.value));
}
function M_checkForm (form) {
   	if (M_notValidEmail (form.get_mail)) {
        alert ('Nezadaný alebo neplatný EMAIL !!');
        return false;
    }
else {
    return true;
	}
}
