
function checkLogin(the_form){
	if (the_form.email.value == ''){
		alert("Please enter your email address");
		return false;
	}
	
	if (the_form.password.value == ''){
		alert("Please enter your password");
		return false;
	}
	
	return true;
}

function checkUser(the_form){
	if (the_form.email.value == ''){
		alert("Please enter your email");
		return false;
	}
	if (the_form.password.value == ''){
		alert("Please enter a password");
		return false;
	}
	if (the_form.password.value.length < 6 || the_form.password.value.length > 8){
		alert("Password has to be 6-8 chars. long");
		return false;
	}
	if (the_form.password.value != the_form.re_password.value){
		alert("Password and Password-Confirmation are different");
		return false;
	}
	return true;
}
	