/* Function to validate the contact form*/
function validateContact()
{
	trimFields();
	var chkd = 0 ;
	if(obj.contact_name.value == '')
	{
		alert('Please enter your Name.');
		obj.contact_name.focus();
		return;
	}
	if(obj.contact_address.value == '')
	{
		alert('Please enter your Contact Address.');
		obj.contact_address.focus();
		return;
	}

	if(obj.contact_email.value == '')
	{
		alert('Please enter Email Address.');
		obj.contact_email.focus();
		return;
	}
	if(!chkEmail(obj.contact_email.value))
	{
		alert('Please enter a valid Email Address.');
		obj.contact_email.select();
		obj.contact_email.focus();
		return;
	}
	if(obj.postal_code.value == '')
	{
		alert("Please enter your Postal Code.");
		obj.postal_code.focus();
		return;
	}
	if(obj.message.value == '')
	{
		alert('Please enter Message.');
		obj.message.focus();
		return;
	}
	if(obj.captcha.value == '')
	{
		alert('Please enter the security code.');
		obj.captcha.focus();
		return;
	}
	obj.action = 'contact_us.html';
	obj.submit();

}
function cancelContact()
{
	var confMsg = 'Are you sure you want to Cancel?';
	if(confirm(confMsg))
	{
		self.location = 'index.html';
	}
}
