function isEmailAddr(email){
	var result = false
	var theStr = new String(email)
	var index = theStr.indexOf("@");
	if (index > 0){
		var pindex = theStr.indexOf(".",index);
		if ((pindex > index+1) && (theStr.length > pindex+1))
			result = true;
		}
	return result;
}

function IsNumeric(sText)
{
   var ValidChars = "0123456789.";
   var IsNumber=true;
   var Char;
   for (i = 0; i < sText.length; i++) 
      { 
      Char = sText.charAt(i); 
      if (ValidChars.indexOf(Char) == -1) 
         {
         IsNumber = false;
         }
	  
      }
   return IsNumber;
 }


function jFeedbackForm() {
	if(document.FeedbackForm.YourName.value.length <3){ 
		alert("Please enter the Name");
		document.FeedbackForm.YourName.focus();
		return (false);
   }
	if (!isEmailAddr(document.FeedbackForm.YourEmail.value)){
		alert("Please enter a complete email address in the form: yourname@yourdomain.com");
		document.FeedbackForm.YourEmail.focus();
		return (false);
	}
	if (document.FeedbackForm.Feedback.value.length < 7){
		alert("Please enter your feedback.");
		document.FeedbackForm.Feedback.focus();
		return (false);
	}
	if (document.FeedbackForm.YourContact.value.length < 7){
		alert("Please enter your handphone or telephone or home number eg. 65-61234567 or CountyCode-Number or CountryCode-AreaCode-Number ");
		document.FeedbackForm.YourContact.focus();
			return (false);	
	}
	if (IsNumeric(document.FeedbackForm.YourContact.value)== false){
		alert("digit only");
		document.FeedbackForm.YourContact.focus();
		return (false);		
	}
	else{
		return true;
	}
}//end func