Forum Moderators: open
The validate onsubmit script below seems to react with the alert box but is not cancelling the action. I can't for the life of me figure out why - I have done numorous other similar scrips. Any help would really be apreaciated.
<HTML>
<HEAD>
<SCRIPT>
//VALIDATE FORM EMAIL
function CheckRequest() {
if(document.RequestReportForm.dest.value.length == 0) {
document.RequestReportForm.dest.focus();
alert("TYPE TEXT MESSAGE HERE");
return false;
}
document.forms[0].submit()
return true;
}
</SCRIPT>
<form name="RequestReportForm" ONSUBMIT="CheckRequest()" action="test.dll" METHOD="POST" >
<INPUT TYPE=submit VALUE="Request Report " class=button">
<input type=text name='dest' style="width=200" size="20" >
</FORM>
</body>
</html>