<html>
<head>
<title>Untitled Document</title>
</head>
<script>
function chk()
{
 var t1 = document.form1.txt1.value;
 alert(t1);
 return false
}
</script>
<body>
<form name=”form1” action=”” method=”post” onSubmit=”return chk()”>
<label>
<input name=”txt1” type=”text” id=”txt1”>
</label>
<label>
<input type=”submit” name=”Submit” value=”ok”>
</label>
</form>
</body>
</html>