答案:最后一个:聊客用来屏蔽不想见到的人admin/hideuser.asp
<%
whoto=request.form("whoto")
user=request.form("user")
screen=request.form("hdish")
chatdata=application("chatdata")
select case screen
case "1"
sendid=finduser(user)
reciid=finduser(whoto)
if sendid<51 and reciid<51 then
if instr(chatdata(sendid,5),",'"&whoto&"'")<1 then
chatdata(sendid,5)=chatdata(sendid,5)&",'"&whoto&"'"
application.lock
application("chatdata")=chatdata
application.unlock
dispstr=right("0"&time,8)&",系统,0,"&user&",ff0000,0,你成功屏蔽"&whoto&"的聊天内容"
else
dispstr=right("0"&time,8)&",系统,0,"&user&",ff0000,0,"&whoto&"已在屏蔽名单中"
end if
else
if reciid=51 then dispstr=right("0"&time,8)&",系统,0,"&user&",ff0000,0,"&whoto&"不在此聊天室"
end if
case "0"
sendid=finduser(user)
reciid=finduser(whoto)
if sendid<51 then
if whoto="所有人" then
chatdata(sendid,5)=""
else
chatdata(sendid,5)=replace(chatdata(sendid,5),",'"&whoto&"'","")
end if
dispstr=right("0"&time,8)&",系统,0,"&user&",ff0000,0,你成功解除对"&whoto&"的聊天内容的屏蔽"
application.lock
application("chatdata")=chatdata
application.unlock
end if
case "2"
sendid=finduser(user)
dispstr=right("0"&time,8)&",系统,0,"&user&",ff0000,0,你屏蔽了:"&mid(replace(chatdata(sendid,5),"'",""),2)
end select
function finduser(fuser)
reval=51
for i=0 to 50
if chatdata(i,0)=fuser then
reval=i
exit for
end if
next
finduser=reval
end function
%>
<script language='javascript'>
parent.comm=new Array('<% =dispstr %>');
parent.writecomm();</script>
<meta http-equiv="refresh" content="60; URL=../refresh.asp?room=<% =room %>&user=<% =user %>">
上一个:音乐开关和图像开关/请勿打挠开关操作文件admin/dontimg.asp
下一个:用ASP+XML打造留言本