?? checkuser.asp
字號:
<%
if Session("Username") = "" or Session("Username") = null then
Response.Write("<script>alert('對不起,您尚未登陸或登陸超時,請重新登陸!');top.location.href='Index.htm';</script>")
Response.End()
end if
Const TableBackColor = "#000000" '表格背景顏色
Const TableTitleColor = "#99A6BF" '表格主單元格顏色
Const TableLeftColor = "#E7EAEF" '表格左單元格言色
Const TableBodyColor = "#FFFFFF" '表格單元格主顏色
Const BackGroundImg = "Images/bg.jpg" '背景圖片
if Session("Admin") = "" or Session("Admin") = null then
end if
'對用戶是否跨用戶登陸進行驗證
dim rs1
Set rs1 = conn.execute( "Select loginSessionID From [userinfo] Where id = " & Session("UID"))
if rs1.BOF or rs1.EOF then
else
if Session.SessionID <> rs1(0) then
Response.Write("<script>alert('對不起,您的用戶已經被盜用,或者被從其他的窗口登陸,請重新登陸!');window.top.location.href='Logout.asp';</script>")
Response.End()
end if
end if
rs1.close()
if Session("refuseIP") <> "" then
'對IP進行過濾
dim Refuse
Refuse = Split(Session("refuseIP"),"|")
dim r
for r = 0 to ubound(Refuse)
if Request.ServerVariables("REMOTE_ADDR") = Refuse(r) then
Response.Write("<script>alert('對不起,您的IP禁止訪問本系統,有任何疑問請聯系管理員!');window.top.location.href='Logout.asp';</script>")
Response.End()
end if
next
end if
if Session("refuseIPsect") <> "" then
'對IP段進行過濾
dim RefuseSect
RefuseSect = Split(Session("refuseIPsect"),"|")
for r = 0 to Ubound(RefuseSect)
if getIPsect(Request.ServerVariables("REMOTE_ADDR")) <> RefuseSect(r) then
Response.Write("<script>alert('對不起,您的IP所在的IP段禁止訪問本系統,有任何疑問請聯系管理員!');window.top.location.href='Logout.asp';</script>")
Response.End()
end if
next
end if
Function getIPsect(ip)
dim cip
cip = Split(ip,".")
getIpsect = cip(0)&"."&cip(1)&"."&cip(2)&".*"
End Function
%>
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -