www.gusucode.com > ASP+ACCESS中学网站设计与实现(论文+源代码+开题报告+任务书) > ASP+ACCESS中学网站设计与实现(论文+源代码+开题报告+任务书)\ASP001中学网站设计与实现\zxweb\lyb\login.asp

    <%@ language=VBScript %>
<!--#include file="setup.asp"-->
<%

if Request("menu") = "login" then
	call login()
elseif Request("menu") = "logout" then
	call logout()
else call index()
end if

sub index()
%>
<html>
<head>
<title>管理登陆</title>
<link rel="stylesheet" href="images/gbook.css">
</head>
<!--#include file="inctop.asp"--><body topmargin=0>
<div align="center"><img src="./images/logo.jpg" width="759" height="110"> </div>
<table width=760 height="27" border=0 align="center" cellpadding=0 cellspacing=1 background="images/dh.gif" style="border: 1px solid #CCCCCC;">
  <tr> 
    <td width="510" height="27"> <img src="images/arrow3.gif" align=absmiddle width="29" height="11"> 
      您的位置: <a href=http://218.3.172.66/jwch><font color="#FF0000"></font></a> 
      >> <a href=index.asp>留言本首页</a> >> <a href=index.asp>浏览留言</a> >> <a href=index.asp></a>管理登陆</td>
    <td width="245"><DIV align=center>【<a href="index.asp">查看留言</a>】  【<a href="write.asp">签写留言</a>】</DIV></td>
  </tr>
</table>
<br>
<table width="760" border="0" cellspacing="1" cellpadding="4" align="center" bgcolor="#999999">
  <form name=reply method="post" action="login.asp"><tr bgcolor="#ebebeb"> 
      <td align="center" bgcolor="#fffff0"> 
        <input type=hidden name=menu value=login>
        <table width="48%" border="0" align="center" cellpadding="3" cellspacing="1" bgcolor="#99CCFF">
          <tr bgcolor="#FFFFFF"> 
            <td width="25%" align="right" nowrap bgcolor="#FFFFF0">管理口令: </td>
            <td width="75%" nowrap bgcolor="#FFFFF0"> 
              <input type="password" name="password" size="20" style="background-color:#ffffff; color:#8888AA; border: 1 double #B4B4B4" onMouseOver = "this.style.backgroundColor = '#E5F0FF'" onMouseOut = "this.style.backgroundColor = ''" value=<%=Request.cookies("password")%>> 
              <input type=checkbox name=save value=save <%if Request.cookies("save") <> "" then%>checked<%end if%>>
              记住密码 </td>
          </tr>
          <tr bgcolor="#FFFFFF"> 
            <td align="center" nowrap bgcolor="#FFFFF0">&nbsp; </td>
            <td nowrap bgcolor="#FFFFF0"> 
              <input type="submit" name="Submit" value="登 陆" style="backgroud-color: #ffffff; border-bottom: 1px solid; border-left: 1px solid; border-right: 1px solid; border-top: 1px solid; FONT-FAMILY: 宋体; FONT-SIZE: 9pt; HEIGHT: 18px; WIDTH: 50px"> 
              <input type="reset" name="Submit2" value="重 置" style="backgroud-color: #ffffff; border-bottom: 1px solid; border-left: 1px solid; border-right: 1px solid; border-top: 1px solid; FONT-FAMILY: 宋体; FONT-SIZE: 9pt; HEIGHT: 18px; WIDTH: 50px"> 
              <input type="button" name="Submit3" value="取 消" onClick="javascript:history.back(-1);" style="backgroud-color: #ffffff; border-bottom: 1px solid; border-left: 1px solid; border-right: 1px solid; border-top: 1px solid; FONT-FAMILY: 宋体; FONT-SIZE: 9pt; HEIGHT: 18px; WIDTH: 50px">
            </td>
          </tr>
        </table>
      </td>
  </tr></form>
</table>
<br>
<table width=760 height="22" border=0 align="center" cellpadding=0 cellspacing=1 background="images/dh.gif" style="border: 1px solid #CCCCCC;">
  <tr> 
    <td width="510" height="18">&nbsp;</td>
    <td width="245">&nbsp;</td>
  </tr>
</table>
<%
call htmlend()

end sub

sub login()

	password = Request.form("password")
	save = Request.form("save")
	if password <> passwords then
	message=message&"您的管理口令不正确!\n"
	end if

	if message <> "" then
	call error(""&message&"")
	Response.end
	end if

	if save <> "" then
	Response.cookies("password") = password
	Response.cookies("save") = save
	else
	Response.cookies("password") = ""
	Response.cookies("save") = ""
	end if

	Response.cookies("admin") = password
	Response.redirect "adminer.asp"

end sub

sub logout()

	Response.cookies("admin") = ""
	Response.cookies("password") = ""
	Response.cookies("save") = ""

	Response.redirect "index.asp"
end sub
%>