﻿function checkForm(o) {
	var msg="";
	
	if (!hasInput(o["naam"])) { msg += "\n- Name"; }
	if (!checkEmail(o["email"].value)) { msg += "\n- E-mail"; }
	if (!checkPhone(o["telefoon"].value, 10)) { msg += "\n- Telephone"; }	
	if (!hasInput(o["bericht"])) { msg += "\n- Message"; }

	if (msg=="")
	{
		return true;
	} else {
		alert("The fields has not been filled or filled incorrectly:"+msg);
		return false;
	}
}
