function bookmarkUs() 
{
	window.external.AddFavorite('http://www.augustademist.com', 'Augusta de Mist - Swellendam Accommodation');
}

function openPop() 
{
	window.open('http://www.oanda.com/convert/classic?user=ruanz', '', 'resizable=yes,scrollbars=yes,width=650,height=420,toolbar=no');
}
 
function enlarge(prefix, picUrl) 
{
	window.open(prefix+"display-popup.html?"+picUrl, "poppis", "resizable=1,HEIGHT=200,WIDTH=200,Left=20%,Top=20%");
}

function enlargeRooms(prefix, picUrl) 
{
	window.open(prefix+"display-popup.html?"+picUrl, "poppis", "resizable=1,HEIGHT=200,WIDTH=200,Left=20%,Top=20%");
}

function validateBookingForm()
{
	fv =  new formValidator();
	
	if (fv.isEmpty("name"))
		fv.raiseError("Your name must be specified.");
		
	if (fv.isEmpty("address"))
		fv.raiseError("Your address must be specified.");
		
	if (fv.isEmpty("country"))
		fv.raiseError("Your country must be specified.");

	if (fv.isEmpty("email"))
		fv.raiseError("Your email address must be specified.");
		
	else
	{	
  		if (!fv.isEmailAddress("email"))
			fv.raiseError("A valid email address must be specified.");
	}
	if (fv.isEmpty("phone"))
		fv.raiseError("Your telephone number must be specified.");
		
	if (fv.isEmpty("guests"))
		fv.raiseError("Number of guests must be specified.");
		

	if (fv.isEmpty("rooms"))
		fv.raiseError("Number of rooms must be specified.");
		
	if (!fv.isChecked("chkProtea") && 
		!fv.isChecked("chkAloe") && 
		!fv.isChecked("chkStrelitzia") && 
		!fv.isChecked("chkRedHotPoker") && 
		!fv.isChecked("chkArum") && 
		!fv.isChecked("chkVarkoor"))
		fv.raiseError("Please select at least 1 preferred room type.");
		
	if (fv.isEmpty("code"))
		fv.raiseError("Spam code must be specified.");		
	
	if (fv.numErrors() > 0)
	{
		fv.displayErrors();
		return false;
	}
	else
	  return true;
}
