//deschide popup
function MM_openBrWindow(theURL,winName,features) { //v2.0
  window.open(theURL,winName,features);
}

// validare formular contact
function trim(Key) {
while(''+Key.charAt(Key.length-1)==' ')
		{ Key=Key.substring(0,Key.length-1); }
	return Key;
}

function validateContact(frmContact) {

	a = document.frmContact;
	a.Nume.value = trim(a.Nume.value);
	a.Telefon.value = trim(a.Telefon.value);
	a.Mesaj.value = trim(a.Mesaj.value);
	
	if (a.Nume.value == '') {
		alert('Va rugam completati campul "Nume, Prenume" !');
		return false;
	}
	
	if (a.Telefon.value == '') {
		alert('Va rugam completati campul "Telefon" !');
		return false;
	}
	
	if (a.Mesaj.value == '') {
		alert('Va rugam completati campul "Mesaj" !');
		return false;
	}
	
	return true;
}

