%
Head()
dim admin_flag
admin_flag=",28,"
if not Dvbbs.master or instr(","&session("flag")&",",admin_flag)=0 then
Errmsg=ErrMsg + "
本页面为管理员专用,请登录后进入。
您没有管理本页面的权限。"
dvbbs_error()
else
call main()
end if
sub main()
dim userip,ips,GetIp1,GetIp2
if request("userip")<>"" then
userip=request("userip")
ips=Split(userIP,".")
If Ubound(ips)=3 Then GetIp1=ips(0)&"."&ips(1)&"."&ips(2)&".*"
end if
if request("action")="add" or request("userip")<>"" then
%>
| IP限制管理--添加 |
<%
dim sip,str1,str2,str3,str4,num_1,num_2
if request.querystring("reaction")="save" then
sip=cstr(request.form("ip1"))
If sip<>"" Then
If Trim(Dvbbs.cachedata(25,0))<>"" Then
sip=Trim(Dvbbs.cachedata(25,0)) & "|" & Replace(sip,"|","")
End If
End If
if sip<>"" then
dvbbs.execute("update dv_setup set Forum_LockIP='"&replace(sip,"'","''")&"'")
reloadsetup
end if
Footer()
%>
| 添加成功! |
<%
else
%>
<%
end if
elseif request("action")="delip" then
userip=request("ips")
'userip=split(userip,chr(10))
userip=split(userip,vbCrLf)
for i = 0 to ubound(userip)
if not (userip(i)="" or userip(i)=" ") then
If i=0 Then
getip1 = userip(i)
Else
getip1 = getip1 & "|" & userip(i)
End If
End If
next
dvbbs.execute("update dv_setup set forum_lockip='"&replace(getip1,"'","''")&"'")
reloadsetup
response.write "更新限制IP成功!"
else
%>