// JavaScript Document

function check(sendmailform)
{
if(document.sendmailform.Name.value=="" || document.sendmailform.Name.value=="Name")
{
	alert("The Name cannot be empty.");
	document.sendmailform.Name.focus();
	return false;
}
else if(document.sendmailform.Mail.value=="" || document.sendmailform.Mail.value=="Email")
{
alert("The e-mail cannot be empty.")
document.sendmailform.Mail.focus();
return false;
}
else if(document.sendmailform.Tel.value=="" || document.sendmailform.Tel.value=="Tel")
{
alert("The Tel cannot be empty.")
document.sendmailform.Tel.focus();
return false;
}
else if(document.sendmailform.Comments.value=="" || document.sendmailform.Comments.value=="Message")
{
alert("Your message cannot be empty.")
document.sendmailform.Comments.focus();
return false;
}

else if(document.sendmailform.Name.value.length<2)
{
	
		alert(" Invalid message or contact information.");
		document.sendmailform.Name.focus();
		return false;
}
else if(document.sendmailform.Comments.value.length<5)
{
		alert(" Invalid message or contact information.");
		document.sendmailform.Comments.focus();
		return false;
}
else  
{
document.sendmailform.submit();
}
}

<!--feedback反馈表页-->
function check_feedback(feedbackform)
{
 if(document.feedbackform.Comments.value=="")
{
alert("Your message cannot be empty.")
document.feedbackform.Comments.focus();
return false;
}
else if(document.feedbackform.Name.value=="")
{
	alert("The Name cannot be empty.");
	document.feedbackform.Name.focus();
	return false;
}
else if(document.feedbackform.Mail.value=="")
{
alert("The e-mail cannot be empty.")
document.feedbackform.Mail.focus();
return false;
}
else if(document.feedbackform.Tel.value=="")
{
alert("The Tel cannot be empty.")
document.feedbackform.Tel.focus();
return false;
}
else if(document.feedbackform.Name.value.length<2)
{
	
		alert(" Invalid message or contact information.");
		document.feedbackform.Name.focus();
		return false;
}
else if(document.feedbackform.Comments.value.length<5)
{
		alert(" Invalid message or contact information.");
		document.feedbackform.Comments.focus();
		return false;
}
else  
{
document.feedbackform.submit();
}
}

<!--产品详细页反馈表页-->
function check_products(sendpoducts)
{

if(document.sendpoducts.Products.value=="")
{
	alert("The Products cannot be empty.");
	document.sendpoducts.Products.focus();
	return false;
}

else if(document.sendpoducts.Companyname.value=="")
{
	alert("The Company Name cannot be empty.");
	document.sendpoducts.Companyname.focus();
	return false;
}
else if(document.sendpoducts.Name.value=="")
{
	alert("The Name cannot be empty.");
	document.sendpoducts.Name.focus();
	return false;
}
else if(document.sendpoducts.Mail.value=="")
{
alert("The e-mail cannot be empty.")
document.sendpoducts.Mail.focus();
return false;
}
else if(document.sendpoducts.Tel.value=="")
{
alert("The Tel cannot be empty.")
document.sendpoducts.Tel.focus();
return false;
}
else if(document.sendpoducts.Comments.value=="")
{
alert("Your message cannot be empty.")
document.sendpoducts.Comments.focus();
return false;
}
else if(document.sendpoducts.Name.value.length<2)
{
	
		alert(" Invalid message or contact information.");
		document.sendpoducts.Name.focus();
		return false;
}
else if(document.sendpoducts.Comments.value.length<5)
{
		alert(" Invalid message or contact information.");
		document.sendpoducts.Comments.focus();
		return false;
}
else  
{
document.sendpoducts.submit();
}
}