// JavaScript Document

function over(object) {
	document.getElementById(object).className = "over";
}

function out(object) {
	document.getElementById(object).className = "button";
}

function checkForm() {
	var fullname = document.myform.fullname.value;
	var email = document.myform.email.value;
	var celltel = document.myform.celltel.value;
	var comments = document.myform.comments.value;
	
	if (fullname == "") {
		alert("Please enter your full name");
		document.myform.fullname.focus();
		return false;
	}
	if (email == "") {
		alert("Please enter your e-mail address");
		document.myform.email.focus();
		return false;
	}
	if (celltel == "") {
		alert("Please enter your cell / tel number");
		document.myform.celltel.focus();
		return false;
	}
	if (comments == "") {
		alert("Please enter your comments");
		document.myform.comments.focus();
		return false;
	}
	if (comments.indexOf("'") != -1) {
		alert("Please remove the apostrophe sign/s from your comments");
		document.myform.comments.focus();
		return false;
	}
	if (comments.indexOf('"') != -1) {
		alert("Please remove the quotation mark/s from your comments");
		document.myform.comments.focus();
		return false;
	}
	document.myform.action = "contactus.php";
	return true;
}
