{
if (form1.fn.value ="")
{
alert("you must type your name")
return false
}
}
//-->
</script>
<form onsubmit="return check()" action=confirm.asp method=post name=form1 >
please fill the folowing form
First Name
<input name=fn >
<INPUT type="submit" value="Submit" name=submit1>
****************************************************
in prvious code i want to first to check if the text box is embty or not ,so it submit the form to asp file.
when i try the code it submit the form to asp without checking it
why??
if (form1.fn.value ="")
{
alert("you must type your name")
return false
}
}
//-->
</script>
<form onsubmit="return check()" action=confirm.asp method=post name=form1 >
please fill the folowing form
First Name
<input name=fn >
<INPUT type="submit" value="Submit" name=submit1>
****************************************************
in prvious code i want to first to check if the text box is embty or not ,so it submit the form to asp file.
when i try the code it submit the form to asp without checking it
why??



Comment