<!--
function validate(frm){

	var strF = frm.txtFName.value;
	var strS = frm.txtSName.value;
	var strE = frm.txtEmail.value;
	var strM = frm.txtMsg.value;
	var chkM = frm.chkMlist.checked;
	// check name entered
	var re = /^[A-Za-z-']+$/
	if(!re.test(strF)){
		if(strF.length == 0){
			alert('Please enter your first name');
		}else{
			alert('Please only enter letters a - z, hyphen (-) or apostrophe (\') in first name');
		}
		frm.txtFName.focus();
		return false;
	}
	if(!re.test(strS)){
		if(strS.length == 0){
			alert('Please enter your surname');
		}else{
			alert('Please only enter letters a - z, hyphen (-) or apostrophe (\') in surname');
		}
		frm.txtSName.focus();
		return false;
	}
	// check email entered and valid
	re = /^.+@.+\..{2,3}$/
	ri = /[\(\)\<\>\,\;\:\\\/\"\[\]]/
	if(!re.test(strE) || (strE.match(ri))){
		alert('Please enter a valid email address')
		frm.txtEmail.focus();
		return false;
	}
	// check either message entered or chkbox checked
	if(!chkM && (strM == '')){
		alert('Please either check the box to join the mailing list or enter a message');		
		frm.chkMlist.focus();
		return false;
	}
	return true;
}
//-->