// Bookings Form Validation
function validateAccom()
{
	fv = new formValidator();
	
	if (fv.isEmpty("your_name"))
		fv.raiseError("Please specify your name.");
	
	if (fv.isEmpty("your_email"))
		fv.raiseError("Please specify your email.");
	else
	{
		if (!fv.isEmailAddress("your_email"))
			fv.raiseError("Please specify a your valid email address.");
	}
		
	if (fv.isEmpty("your_country"))
		fv.raiseError("Please specify your coutry.");
		
	if (fv.isEmpty("your_phone"))
		fv.raiseError("Please specify your phone number.");
		
	if (fv.isEmpty("no_guests"))
		fv.raiseError("Please specify the number of guests.");
		
	if (fv.isEmpty("day_in"))
		fv.raiseError("Please specify your check in date.");
		
	if (fv.isEmpty("day_out"))
		fv.raiseError("Please specify your check out date.");
		
	if (fv.numErrors() > 0)
	{
		fv.displayErrors();
		return false;
	}
	else
		return true;	
}

function openMap() {
	window.open('floormap.shtml','','resizable=no,scrollbars=no,width=730,height=627');
}

function validateContact()
{
	fv = new formValidator();
	
	if (fv.isEmpty("your_name"))
		fv.raiseError("Please specify your name.");
	
	if (fv.isEmpty("your_email"))
		fv.raiseError("Please specify your email.");
	else
	{
		if (!fv.isEmailAddress("your_email"))
			fv.raiseError("Please specify a your valid email address.");
	}
		
	if (fv.isEmpty("your_country"))
		fv.raiseError("Please specify your coutry.");
		
	if (fv.isEmpty("your_phone"))
		fv.raiseError("Please specify your phone number.");
		
	if (fv.numErrors() > 0)
	{
		fv.displayErrors();
		return false;
	}
	else
		return true;	
}
