📄 admin_lib.asp
字号:
<%
dim ulogin,isad,username,check_user
sub checkuser()
Username=Session("username"&dlog_session)
Password=Session("password"&dlog_session)
if username="" or password="" then
Username=replace(request.Cookies(dlog_cookies_name)("Username"),"'","")
Password=replace(request.Cookies(dlog_cookies_name)("Password"),"'","")
end if
sql= "SELECT isad FROM User_MDB where username = '" & Username & "' and password='" & Password & "'"
set rs_inc=conn.Execute(sql)
if not (rs_inc.BOF or rs_inc.eof) then
ulogin="true"
Session("username"&dlog_session) = Username
Session("password"&dlog_session) = Password
Session("isad"&dlog_session)=rs_inc("isad")
isad=Session("isad"&dlog_session)
end if
rs_inc.Close()
set rs_inc=nothing
if uLogin = "true" then
response.write " WelCome!! <b>" & username & "</B> <BR> HERE:日志设置中心<BR> <a href=../logout.asp target=_parent>退出登陆</a> | <a href=../index.asp target=_top>返回日志首页</a><br> "
else
response.write " 无身份标志者入侵<br> | <a href=../login.asp target=_top>登陆</a> | <a href=javascript:history.go(-1)>返回</a> | "
end if
if isad=-1 then
response.write " <br>[ 您现在可操作 ]<br> "
else
response.write " <br>[ 您现在不可操作 ]<br> "
end if
end sub
'==================================================================
'==================================================================
function CovHtml(content)
ON ERROR RESUME NEXT
CovHtml=content
if not isnull(content) then
CovHtml=replace(CovHtml,"&","&")
CovHtml=replace(CovHtml,"<","<")
CovHtml=replace(CovHtml,">",">")
CovHtml=replace(CovHtml,chr(34),""")
CovHtml=replace(CovHtml,chr(39),"'")
end if
if Err.Number <>0 then
CovHtml= "CovHtml转换中出错请联系管理员<br>"
Err.Clear
end if
end function
'=================================================================
'=================================================================
function unCovHtml(content)
ON ERROR RESUME NEXT
unCovHtml=content
if not isnull(content) then
unCovHtml=replace(unCovHtml,"&","&",1,-1,1)
unCovHtml=replace(unCovHtml," ",chr(32),1,-1,1)
unCovHtml=replace(unCovHtml,"<","<",1,-1,1)
unCovHtml=replace(unCovHtml,">",">",1,-1,1)
unCovHtml=replace(unCovHtml,""",chr(34),1,-1,1)
end if
if Err.Number <>0 then
unCovHtml= "unCovHtml转换中出错请联系管理员<br>"
Err.Clear
end if
end function
'=================================================================
'==================================================================
SUB MESSAGE(error) '错误页面 %>
<table width="100%" height="100%">
<tr>
<td style="color:red" align="center"><%=error%> | <a href="javascript:history.go(-1)">BACK</a></td>
</tr>
</table>
<%
'set ASPBook=nothing
'conn.Close
'set conn = nothing
end sub
'=================================================================
function furl(url)
furl=replace(url," ","%20",1,-1,1)
end function
'=================================================================
'========================================================================
sub redirect(url,success) '操作成功页面 %>
<meta http-equiv=refresh content="0; url=<%=url%>">
<table width=100% height=100%><tr><td align=center><%=success%> | Back To <a href="index.asp">Home</a></td></tr></table>
<%end sub
'====================================================
Mypagesize =5 '每页显示多条
Color1 = "#f0f0f0" '框架循环颜色
Color2 = "#ffffff" '框架循环颜色
Color3 = "#ff6c00" '页面背景颜色
%>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -