Vbscript
Vbscript
1
<br> <input type="reset">
<input type="button" name="cmdlogin" </body>
value="login" onclick="validate()"> </html>
<input type="reset">
</body>
</html>
If document.f1.txtlogin.value="" Then
msgbox "Enter some value!"
elseif a="y" and b="u" then
msgbox "Login success"
cookievalue=(document.f1.txtlogin.value)
document.cookie="name=" +
cookievalue
msgbox "Setting Cookies : " &
"name=" & cookievalue
else
msgbox "Login Failed.....Try
Again"
End If
end sub
</script>
</head>
<body>
<p align="center">
<h1>Login Form</h1>
<br>
<form name="f1">
Login Id<input type="text" name="txtlogin">
<br>
Password<input type="password"
name="txtpw">
<br>
<input type="button" name="cmdlogin"
value="login" onclick="validate()">