function validateApplication()
{
	fv = new formValidator();
	
	if (fv.isEmpty("establishmentName"))
		fv.raiseError("Please specify the name of the establishment you wish to advertise.");
	
	if (fv.isEmpty("adminName"))
		fv.raiseError("Please specify the contact name for administrative and billing purposes.");
	
	if (fv.isEmpty("adminEmail"))
		fv.raiseError("Please specify an email address for administrative and billing purposes.");
	else
	{
		if (!fv.isEmailAddress("adminEmail"))
			fv.raiseError("Please specify a valid email address for administrative and billing purposes.");
	}

	if (fv.isEmpty("verifyAdminEmail"))
		fv.raiseError("Please verify the e-mail address for administrative and billing purposes.");
	else
	{
		if (fv.findObj("verifyAdminEmail").value != fv.findObj("adminEmail").value)
			fv.raiseError("The email address and verified email address for administrative and billing purposes do not match. Please re-enter.");
	}

	if (fv.isEmpty("adminTelephone"))
		fv.raiseError("Please enter the telephone number for administrative and billing purposes.");
		
	if (fv.isEmpty("reserveEmail"))
		fv.raiseError("Please specify an email address for reservations.");
	else
	{
		if (!fv.isEmailAddress("reserveEmail"))
			fv.raiseError("Please specify a valid email address for reservations.");
	}

	if (fv.isEmpty("verifyReserveEmail"))
		fv.raiseError("Please verify the e-mail address for reservations.");
	else
	{
		if (fv.findObj("verifyReserveEmail").value != fv.findObj("reserveEmail").value)
			fv.raiseError("The email address and verified email address for reservations do not match. Please re-enter.");
	}

	if (fv.isEmpty("reserveTelephone"))
		fv.raiseError("Please enter the telephone number for reservations.");
		
	if (fv.isEmpty("code"))
		fv.raiseError("Please enter the code used for our spam checks.");
		
	if (fv.numErrors() > 0)
	{
		fv.displayErrors();
		return false;
	}
	else
		return true;
}

function validateForm()
{
	fv = new formValidator();
	
	if (fv.isEmpty("Name"))
		fv.raiseError("Please specify your name.");
	
	if (fv.isEmpty("Email"))
		fv.raiseError("Please specify an email address.");
	else
	{
		if (!fv.isEmailAddress("Email"))
			fv.raiseError("Please specify a valid email address.");
	}

	if (fv.isEmpty("RepeatEmail"))
		fv.raiseError("Please verify your e-mail address.");
	else
	{
		if (fv.findObj("RepeatEmail").value != fv.findObj("Email").value)
			fv.raiseError("The email address and verified email address do not match. Please re-enter.");
	}

	if (fv.isEmpty("NumberAdults"))
		fv.raiseError("Please enter the number of adults.");
		
	if (fv.isEmpty("code"))
		fv.raiseError("Please enter the code used for our spam checks.");
		
	if (fv.numErrors() > 0)
	{
		fv.displayErrors();
		return false;
	}
	else
		return true;
}

function validateTourForm()
{
	fv = new formValidator();
	
	if (fv.isEmpty("Name"))
		fv.raiseError("Please specify your name.");
	
	if (fv.isEmpty("Email"))
		fv.raiseError("Please specify an email address.");
	else
	{
		if (!fv.isEmailAddress("Email"))
			fv.raiseError("Please specify a valid email address.");
	}
	
	if (fv.isEmpty("RepeatEmail"))
		fv.raiseError("Please verify your e-mail address.");
	else
	{
		if (fv.findObj("RepeatEmail").value != fv.findObj("Email").value)
			fv.raiseError("The email address and verified email address do not match. Please re-enter.");
	}

	if (fv.findObj("EnquiryFor").value == "Not Specified")
		fv.raiseError("Please specify what your enquiry is for.");

	if (fv.isEmpty("NumberAdults"))
		fv.raiseError("Please enter the number of adults.");
		
	if (fv.isEmpty("code"))
		fv.raiseError("Please enter the code used for our spam checks.");
		
	if (fv.numErrors() > 0)
	{
		fv.displayErrors();
		return false;
	}
	else
		return true;
}

function validateTranspForm()
{
	fv = new formValidator();
	
	if (fv.isEmpty("Name"))
		fv.raiseError("Please specify your name.");
	
	if (fv.isEmpty("Email"))
		fv.raiseError("Please specify an email address.");
	else
	{
		if (!fv.isEmailAddress("Email"))
			fv.raiseError("Please specify a valid email address.");
	}
	
	if (fv.isEmpty("RepeatEmail"))
		fv.raiseError("Please verify your e-mail address.");
	else
	{
		if (fv.findObj("RepeatEmail").value != fv.findObj("Email").value)
			fv.raiseError("The email address and verified email address do not match. Please re-enter.");
	}

	if (fv.isEmpty("PickUp"))
		fv.raiseError("Please enter the pick-up location.");
		
	if (fv.isEmpty("DropOff"))
		fv.raiseError("Please enter the drop-off location.");
		
	if (fv.isEmpty("ConfirmDays"))
		fv.raiseError("Please confirm the number of rental days.");
		
	if (fv.isEmpty("code"))
		fv.raiseError("Please enter the code used for our spam checks.");
		
	if (fv.numErrors() > 0)
	{
		fv.displayErrors();
		return false;
	}
	else
		return true;
}

function validateBazBusForm()
{
	fv = new formValidator();
	
	if (fv.isEmpty("Name"))
		fv.raiseError("Please specify your name.");
	
	if (fv.isEmpty("Email"))
		fv.raiseError("Please specify an email address.");
	else
	{
		if (!fv.isEmailAddress("Email"))
			fv.raiseError("Please specify a valid email address.");
	}
	
	if (fv.isEmpty("RepeatEmail"))
		fv.raiseError("Please verify your e-mail address.");
	else
	{
		if (fv.findObj("RepeatEmail").value != fv.findObj("Email").value)
			fv.raiseError("The email address and verified email address do not match. Please re-enter.");
	}

	if (fv.isEmpty("code"))
		fv.raiseError("Please enter the code used for our spam checks.");
		
	if (fv.numErrors() > 0)
	{
		fv.displayErrors();
		return false;
	}
	else
		return true;
}

function validateWeddingForm()
{
	fv = new formValidator();
	
	if (fv.isEmpty("Name"))
		fv.raiseError("Please specify your name.");
	
	if (fv.isEmpty("Email"))
		fv.raiseError("Please specify an email address.");
	else
	{
		if (!fv.isEmailAddress("Email"))
			fv.raiseError("Please specify a valid email address.");
	}
	
	if (fv.isEmpty("RepeatEmail"))
		fv.raiseError("Please verify your e-mail address.");
	else
	{
		if (fv.findObj("RepeatEmail").value != fv.findObj("Email").value)
			fv.raiseError("The email address and verified email address do not match. Please re-enter.");
	}

	if (fv.isEmpty("code"))
		fv.raiseError("Please enter the code used for our spam checks.");
		
	if (fv.numErrors() > 0)
	{
		fv.displayErrors();
		return false;
	}
	else
		return true;
}

function validateContact()
{
	fv = new formValidator();
	
	if (fv.isEmpty("Name"))
		fv.raiseError("Please specify your name.");
	
	if (fv.isEmpty("Email"))
		fv.raiseError("Please specify an email address.");
	else
	{
		if (!fv.isEmailAddress("Email"))
			fv.raiseError("Please specify a valid email address.");
	}
	
	if (fv.isEmpty("Questions"))
		fv.raiseError("Please enter a comment or any questions.");
		
	if (fv.numErrors() > 0)
	{
		fv.displayErrors();
		return false;
	}
	else
		return true;
}

function validateGuestReview()
{
	fv = new formValidator();
	
	if (fv.isEmpty("Name"))
		fv.raiseError("Please specify your name.");

	if (fv.isEmpty("Email"))
		fv.raiseError("Please specify your email address.")
	else
	{
		if (!fv.isEmailAddress("Email"))
			fv.raiseError("Please specify a valid email address.")
	}
	
	if (fv.isEmpty("Location"))
		fv.raiseError("Please specify your location.");
		
	if (fv.findObj("StayMonth").value == "Not Specified" ||
		fv.findObj("StayYear").value == "Not Specified")
		fv.raiseError("Please specify the date you stayed at this particular establishment.");
	
	if (!fv.isSelected("impression"))
		fv.raiseError("Please specify your overall impression.");

	if (fv.isEmpty("Review"))
		fv.raiseError("Please enter your review.");

	if (fv.isEmpty("code"))
		fv.raiseError("Please enter the code used for our spam checks.");
		
	if (fv.numErrors() > 0)
	{
		fv.displayErrors();
		return false;
	}
	else
		return true;
}

function validateSuburbReview()
{
	fv = new formValidator();
	
	if (fv.isEmpty("Name"))
		fv.raiseError("Please specify your name.");

	if (fv.isEmpty("Email"))
		fv.raiseError("Please specify your email address.")
	else
	{
		if (!fv.isEmailAddress("Email"))
			fv.raiseError("Please specify a valid email address.")
	}
	
	if (fv.isEmpty("Location"))
		fv.raiseError("Please specify your city of residence.");
		
	if (fv.findObj("VisitMonth").value == "Not Specified" ||
		fv.findObj("VisitYear").value == "Not Specified")
		fv.raiseError("Please specify the date you visited this town/suburb.");
	
	if (!fv.isSelected("impression"))
		fv.raiseError("Please specify your overall impression.");

	if (fv.isEmpty("Review"))
		fv.raiseError("Please enter your review.");

	if (fv.isEmpty("code"))
		fv.raiseError("Please enter the code used for our spam checks.");
		
	if (fv.numErrors() > 0)
	{
		fv.displayErrors();
		return false;
	}
	else
		return true;
}

function validateWeddingReview()
{
	fv = new formValidator();
	
	if (fv.isEmpty("Name"))
		fv.raiseError("Please specify your name.");

	if (fv.isEmpty("Email"))
		fv.raiseError("Please specify your email address.")
	else
	{
		if (!fv.isEmailAddress("Email"))
			fv.raiseError("Please specify a valid email address.")
	}
	
	if (fv.isEmpty("Location"))
		fv.raiseError("Please specify your location.");
		
	if (fv.findObj("WeddingMonth").value == "Not Specified" ||
		fv.findObj("WeddingYear").value == "Not Specified")
		fv.raiseError("Please specify the date of the wedding for which you are submitting a review.");
	
	if (!fv.isSelected("impression"))
		fv.raiseError("Please specify your overall impression.");

	if (fv.isEmpty("Review"))
		fv.raiseError("Please enter your review.");

	if (fv.isEmpty("code"))
		fv.raiseError("Please enter the code used for our spam checks.");
		
	if (fv.numErrors() > 0)
	{
		fv.displayErrors();
		return false;
	}
	else
		return true;
}

function validateTranspReview()
{
	fv = new formValidator();
	
	if (fv.isEmpty("Name"))
		fv.raiseError("Please specify your name.");

	if (fv.isEmpty("Email"))
		fv.raiseError("Please specify your email address.")
	else
	{
		if (!fv.isEmailAddress("Email"))
			fv.raiseError("Please specify a valid email address.")
	}
	
	if (fv.isEmpty("Location"))
		fv.raiseError("Please specify your location.");
		
	if (fv.findObj("RentalMonth").value == "Not Specified" ||
		fv.findObj("RentalYear").value == "Not Specified")
		fv.raiseError("Please specify the date of the rental for which you are submitting a review.");
	
	if (!fv.isSelected("impression"))
		fv.raiseError("Please specify your overall impression.");

	if (fv.isEmpty("Review"))
		fv.raiseError("Please enter your review.");

	if (fv.isEmpty("code"))
		fv.raiseError("Please enter the code used for our spam checks.");
		
	if (fv.numErrors() > 0)
	{
		fv.displayErrors();
		return false;
	}
	else
		return true;
}

function validateItineraryReview()
{
	fv = new formValidator();
	
	if (fv.isEmpty("Name"))
		fv.raiseError("Please specify your name.");

	if (fv.isEmpty("Email"))
		fv.raiseError("Please specify your email address.")
	else
	{
		if (!fv.isEmailAddress("Email"))
			fv.raiseError("Please specify a valid email address.")
	}
	
	if (fv.isEmpty("Location"))
		fv.raiseError("Please specify your location.");
		
	if (fv.findObj("TourMonth").value == "Not Specified" ||
		fv.findObj("TourYear").value == "Not Specified")
		fv.raiseError("Please specify the date you dealt with this company.");

	if (!fv.isSelected("impression"))
		fv.raiseError("Please specify your overall impression.");
		
	if (fv.isEmpty("TourName"))
		fv.raiseError("Please select what your review is for.");

	if (fv.isEmpty("Review"))
		fv.raiseError("Please enter your review.");

	if (fv.isEmpty("code"))
		fv.raiseError("Please enter the code used for our spam checks.");

	if (fv.numErrors() > 0)
	{
		fv.displayErrors();
		return false;
	}
	else
		return true;
}
