<!--------index.asp---------->
<style>
body,form,table{ font-size:12px;font-family:Verdana}
.inp{ border-left:white;border-top:white;border-right:white;border-bottom:1px solid gray; width:80px}
</style>
<%
if request.Cookies("User")("Name")="" then
%>
<form method=post name=login action=login.asp>
<div align=center>
<table cellspacing=5 cellpadding=5>
<tr>
<td colspan=2>您还没有登录!</td>
</tr>
<tr>
<td width=60 align=right>用户名: </td><td align=left><input name=Name class=inp></td>
</tr>
<tr>
<td width=60 align=right>密 码: </td><td align=left><input name=Pwd class=inp type=password></td>
</tr>
<tr>
<td width=60 align=right>保存期限: </td><td align=left><select name=Cookies_Time>
<option value=1>1
<option value=7>1周
</select></td>
</tr>
<tr>
<td colspan=2><input type=submit value=提交></td>
</tr>
</form>
<%
else
%>
<span style="font-size:12px;font-family:Verdana">欢迎您,</span><%=request.cookies("User")("Name")%>。
<%
end if
%>
<!-------------login.asp----------->
<%
Response.Cookies("User")("Name")= request("Name")
Response.Cookies("User")("Pwd")= request("Pwd")
Cookies_Time=request.form("Cookies_Time")
if Cookies_Time="" then Cookies_Time=1
if Cookies_Time<>"0" then
Cookies_Time=dateadd("d",Cookies_Time,date())
Res
<style>
body,form,table{ font-size:12px;font-family:Verdana}
.inp{ border-left:white;border-top:white;border-right:white;border-bottom:1px solid gray; width:80px}
</style>
<%
if request.Cookies("User")("Name")="" then
%>
<form method=post name=login action=login.asp>
<div align=center>
<table cellspacing=5 cellpadding=5>
<tr>
<td colspan=2>您还没有登录!</td>
</tr>
<tr>
<td width=60 align=right>用户名: </td><td align=left><input name=Name class=inp></td>
</tr>
<tr>
<td width=60 align=right>密 码: </td><td align=left><input name=Pwd class=inp type=password></td>
</tr>
<tr>
<td width=60 align=right>保存期限: </td><td align=left><select name=Cookies_Time>
<option value=1>1
<option value=7>1周
</select></td>
</tr>
<tr>
<td colspan=2><input type=submit value=提交></td>
</tr>
</form>
<%
else
%>
<span style="font-size:12px;font-family:Verdana">欢迎您,</span><%=request.cookies("User")("Name")%>。
<%
end if
%>
<!-------------login.asp----------->
<%
Response.Cookies("User")("Name")= request("Name")
Response.Cookies("User")("Pwd")= request("Pwd")
Cookies_Time=request.form("Cookies_Time")
if Cookies_Time="" then Cookies_Time=1
if Cookies_Time<>"0" then
Cookies_Time=dateadd("d",Cookies_Time,date())
Res
| 对此文章发表了评论 |
