<form name="login" action="loginDo.asp">
<table>
<tr>
<td>用户名</td>
<td><input type="textbox" name="username" value=""></td>
</tr>
<tr>
<td>密码</td>
<td><input type="textbox" name="password" value=""></td>
</tr>
</table>
<input type="submit" value="登陆">
</form>
<%
username = request.querystring("username")
password = request.querystring("password")
if username = "fangxiangliaofa" and password = "123456" then
session("login") = "yes"
response.write "您已经成功登陆"
else
response.write "用户名密码错误,请从新登陆"
end if
%>
<%
if session("login")="" then
Response.Redirect("login.asp")
end if
%>