/* ClearForm: this function has 1 argument: form.
   It clears the input and answer fields on the form. 
   It needs to know the names of the INPUT elements in order
   to do this. */
function ClearForm(form) {
	form.service_type.value = "selected";
	form.name.value = "";
	form.email.value = "";
	form.phone.value = "";
	form.pages.value = "";
	form.comment.value = "";
}


//JavaScript function to confirm validation
function checkform(thisform) {
	if (thisform.email_options.selectedIndex==0)
	{
	alert ("Please select a service you want more information about");
	thisform.email_options.focus();
	//thisform.service_type.select();
	completed = false;
	}
	if (thisform.name.value == null || thisform.name.value == "")
	{
	alert ("Please enter your Name");
	thisform.name.focus();
	thisform.name.select();
	return false;
	}
	if (thisform.Email.value == null || thisform.Email.value == "")
	{
	alert ("Please enter your Email Address");
	thisform.Email.focus();
	thisform.Email.select();
	return false;
	}
	if (thisform.pages.value == null || thisform.pages.value == "")
	{
	alert ("Please enter the Number of Pages you think you will need");
	thisform.pages.focus();
	thisform.pages.select();
	return false;
	}
	if (thisform.comments.value == null || thisform.comments.value == "")
	{
	alert ("Please enter something in the comments box before sending the email");
	thisform.comments.focus();
	thisform.comments.select();
	return false;
	}
}
