admin.asp
来自「个人主页全站v2.0 个人主页全站v2.0 个人主页全站v2.0」· ASP 代码 · 共 55 行
ASP
55 行
<!--#include file="conn.asp"-->
<%
UserName=trim(request("UserName"))
PassWord=trim(request("PassWord"))
if username="" or password="" then
%>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<link rel="stylesheet" href="images/font.css" type="text/css">
</head>
<body oncontextmenu="return false" ondragstart="return false" onselectstart="return false" onkeydown='if(event.ctrlKey)return false;'>
<div align="center">
<center>
<table border="1" width="200" height="155" cellspacing="1" cellpadding="0" bordercolor="#86540C">
<tr>
<td width="346" height="34" colspan="2" align="center"><b>管理登陆</b></td>
</tr>
<tr><form method="post" action="Admin.asp">
<td width="150" height="41" align="center">名称:</td>
<td width="150" height="41" align="center">
<input type="text" name="Username" size="22" style="width: 90; height: 19">
</td>
</tr>
<tr>
<td width="193" height="45" align="center">密码:</td>
<td width="196" height="45" align="center">
<input type="password" name="PassWord" size="22" style="width: 89; height: 19">
</td>
</tr>
<tr>
<td width="300" height="38" align="center" colspan="2"><input type="submit" name="Submit" value="[确定]" class="bt">
<input type="reset" name="exit" value="退出" class="bt" onClick="Javascript:window.location='exit.asp'"></td></form>
</tr></form>
</table>
</center>
</div>
</body>
</html>
<%
else
set rs=server.createobject("adodb.recordset")
sql="select * from admin where user='"&username&"' and pass='"&password&"'"
set rs=conn.execute(sql)
if not(rs.bof or rs.eof) then
session("musicadmin")=username
session("musicpass")=password
response.redirect "adminsave.asp"
else
response.write"<script>alert('用户名密码错误');location.href='javascript:history.back()'</script>"
end if
rs.close
set rs=nothing
end if
%>
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?