function frmValid(theForm) {
	// must have a name
	t = theForm.TxtName.value.toLowerCase();
	if( t == "" || t.length < 3 || t.indexOf("abc") >= 0 || t.indexOf("xyz") >= 0 || t.indexOf("fuck") >= 0 ){
		alert("Please enter your Name.");
		theForm.TxtName.focus();
		return (false);
	}
	// must have a last name
	t = theForm.TxtLName.value.toLowerCase();
	if( t == "" || t.length < 3 || t.indexOf("abc") >= 0 || t.indexOf("xyz") >= 0 || t.indexOf("fuck") >= 0 ){
		alert("Please enter your Last Name.");
		theForm.TxtLName.focus();
		return (false);
	}
	// check e-mail
	t = theForm.TxtEmail.value;
	if( t == "your@company.com" || t == "" || t.indexOf("@") == -1 || t.indexOf(".") == -1 || t.indexOf(" ")!=-1 || t.length < 6 || t.indexOf("xyz.com") > 0 || t.indexOf("abc.com") > 0 || t.indexOf("jagatniwaspalace.com") > 0 ) {
		alert("Your Email seems to be invalid!");
		theForm.TxtEmail.focus();
		return (false);
	}

	// Industry
	t = theForm.CmbIndustry.value;
//	alert (t);
if( t == "" || t == "Select" || parseFloat(t) <= 0 ){
		alert("Please select Industry.");
		theForm.CmbIndustry.focus();
		return (false);
	}
	// Interest
	if(theForm.ChkIntrest1.checked == false && theForm.ChkIntrest2.checked == false && theForm.ChkIntrest3.checked == false && theForm.ChkIntrest4.checked == false && theForm.ChkIntrest5.checked == false && theForm.ChkIntrest6.checked == false && theForm.ChkIntrest7.checked == false && theForm.ChkIntrest8.checked == false)
	{
		alert("Please Choose at least one interest");
		return false;
	}
	t = theForm.TxtAnyAsk.value.toLowerCase();
	if( t.length < 3 || t.indexOf("abc") >= 0 || t.indexOf("xyz") >= 0 || t.indexOf("fuck") >= 0 ){
		alert("Please enter valid information.");
		theForm.TxtAnyAsk.focus();
		return (false);
	}
}

function frmValidContactUs(theForm) {
	// must have a name
	t = theForm.TxtName.value.toLowerCase();
	if( t == "" || t.length < 3 || t.indexOf("abc") >= 0 || t.indexOf("xyz") >= 0 || t.indexOf("fuck") >= 0 ){
		alert("Please enter your Name.");
		theForm.TxtName.focus();
		return (false);
	}
	// check e-mail
	t = theForm.TxtEmail.value;
	if( t == "your@company.com" || t == "" || t.indexOf("@") == -1 || t.indexOf(".") == -1 || t.indexOf(" ")!=-1 || t.length < 6 || t.indexOf("xyz.com") > 0 || t.indexOf("abc.com") > 0 || t.indexOf("jagatniwaspalace.com") > 0 ) {
		alert("Your Email seems to be invalid!");
		theForm.TxtEmail.focus();
		return (false);
	}
}
function frmValidSendToUrFriends(theForm) {
	// must have a name
	t = theForm.TxtUrName.value.toLowerCase();
	if( t == "" || t.length < 3 || t.indexOf("abc") >= 0 || t.indexOf("xyz") >= 0 || t.indexOf("fuck") >= 0 ){
		alert("Please enter your Name.");
		theForm.TxtUrName.focus();
		return (false);
	}
	// check e-mail
	t = theForm.TxtUrEmail.value;
	if( t == "your@company.com" || t == "" || t.indexOf("@") == -1 || t.indexOf(".") == -1 || t.indexOf(" ")!=-1 || t.length < 6 || t.indexOf("xyz.com") > 0 || t.indexOf("abc.com") > 0 || t.indexOf("jagatniwaspalace.com") > 0 ) {
		alert("Your Your Email seems to be invalid!");
		theForm.TxtUrEmail.focus();
		return (false);
	}
	// check e-mail
	t = theForm.TxtUrFriendsEmail.value;
	if( t == "your@company.com" || t == "" || t.indexOf("@") == -1 || t.indexOf(".") == -1 || t.indexOf(" ")!=-1 || t.length < 6 || t.indexOf("xyz.com") > 0 || t.indexOf("abc.com") > 0 || t.indexOf("jagatniwaspalace.com") > 0 ) {
		alert("Your Your Friends Email seems to be invalid!");
		theForm.TxtUrFriendsEmail.focus();
		return (false);
	}
}

function frmValidFeedback(theForm) {
	// must have a name
	t = theForm.TxtName.value.toLowerCase();
	if( t == "" || t.length < 3 || t.indexOf("abc") >= 0 || t.indexOf("xyz") >= 0 || t.indexOf("fuck") >= 0 ){
		alert("Please enter your Name.");
		theForm.TxtName.focus();
		return (false);
	}
	// must have a last name
	t = theForm.TxtCountry.value.toLowerCase();
	if( t == "" || t.length < 3 || t.indexOf("abc") >= 0 || t.indexOf("xyz") >= 0 || t.indexOf("fuck") >= 0 ){
		alert("Please enter Country.");
		theForm.TxtCountry.focus();
		return (false);
	}
// check e-mail
	t = theForm.TxtEmail.value;
	if( t == "your@company.com" || t == "" || t.indexOf("@") == -1 || t.indexOf(".") == -1 || t.indexOf(" ")!=-1 || t.length < 6 || t.indexOf("xyz.com") > 0 || t.indexOf("abc.com") > 0 || t.indexOf("jagatniwaspalace.com") > 0 ) {
		alert("Your Email seems to be invalid!");
		theForm.TxtEmail.focus();
		return (false);
	}

	// Industry
	t = theForm.CmbImprove.value;
//	alert (t);
	if( t == "" || t == "Select" || parseFloat(t) <= 0 ){
		alert("Please select a choice.");
		theForm.CmbImprove.focus();
		return (false);
	}
	// Interest
	if(t == "Others")
	{
		t = theForm.TxtImprove.value.toLowerCase();
		if( t.length < 3 || t.indexOf("abc") >= 0 || t.indexOf("xyz") >= 0 || t.indexOf("fuck") >= 0 )
		{
			alert("Please enter some text.");
			theForm.TxtImprove.focus();
			return (false);
		}
	}
}





function frmValidPartner(theForm) {
	// buddy must have a first name
	t = theForm.fname.value.toLowerCase();
	if( t == "" || t.length < 3 || t.indexOf("abc") >= 0 || t.indexOf("xyz") >= 0 || t.indexOf("fuck") >= 0 ){
		alert("Please enter your First Name.");
		theForm.fname.focus();
		return (false);
	}


	// buddy must have a last name
	t = theForm.lname.value.toLowerCase();
	if( t == "" || t.length < 3 || t.indexOf("abc") >= 0 || t.indexOf("xyz") >= 0 || t.indexOf("fuck") >= 0 ){
		alert("Please enter your Last Name.");
		theForm.lname.focus();
		return (false);
	}
	
		// buddy must have a address
	t = theForm.Address.value.toLowerCase();
	if( t == "" || t.length < 3 || t.indexOf("abc") >= 0 || t.indexOf("xyz") >= 0 || t.indexOf("fuck") >= 0 ){
		alert("Please enter your Address.");
		theForm.Address.focus();
		return (false);
	}
	
	// buddy must have a city
	t = theForm.city.value.toLowerCase();
	if( t == "" || t.length < 1 || t.indexOf("abc") >= 0 || t.indexOf("xyz") >= 0 || t.indexOf("fuck") >= 0 ){
		alert("Please enter your City.");
		theForm.city.focus();
		return (false);
	}
	
	// buddy must have a zip.
	t = theForm.zip.value.toLowerCase();
	if( t == "" || t.length < 1 || t.indexOf("abc") >= 0 || t.indexOf("xyz") >= 0 || t.indexOf("fuck") >= 0 ){
		alert("Please enter your Zip/PostalCode.");
		theForm.zip.focus();
		return (false);
	}
	
	// buddy must have a country
	t = theForm.country.value.toLowerCase();
	if( t == "" || t.length < 1 || t.indexOf("abc") >= 0 || t.indexOf("xyz") >= 0 || t.indexOf("fuck") >= 0 ){
		alert("Please enter your Country.");
		theForm.country.focus();
		return (false);
	}

	// check e-mail
	t = theForm.email.value;
	if( t == "your@company.com" || t == "" || t.indexOf("@") == -1 || t.indexOf(".") == -1 || t.indexOf(" ")!=-1 || t.length < 6 || t.indexOf("xyz.com") > 0 || t.indexOf("abc.com") > 0 || t.indexOf("jagatniwaspalace.com") > 0 ) {
		alert("Your Email seems to be invalid!");
		theForm.email.focus();
		return (false);
	}
	
	
	// buddy must have a phone
	t = theForm.phone.value.toLowerCase();
	if( t == "" || t.length < 3 || t.indexOf("abc") >= 0 || t.indexOf("xyz") >= 0 || t.indexOf("fuck") >= 0 ){
		alert("Please enter your Phone No.");
		theForm.phone.focus();
		return (false);
	}
	
	// all's well ends well
	return true;
}

