<!--#include file="inc_const.asp"-->
<%response.expires=0
Response.CacheControl = "Private"
application.lock

set cschat=server.createobject("ffcschat.cssbchat")
my_level=cschat.getLevel(Session,Application(ConstStr & "_user_list"),Application(ConstStr & "_room_list"))

application.unlock
if my_level=0 then
  set cschat=nothing
  response.redirect("showerr.asp")  
  response.end
end if
myname=cschat.myname
room_id=cschat.room_id
true_level=cint(cschat.getListvalue(Application( ConstStr & "_user_list"),myname,3))

set cschat=nothing

room_array=split(Application( ConstStr & "_room_list"),"<$"&room_id&"$>")
room_array2=split(room_array(1),"$>")
if lcase(myname)=lcase(room_array2(1)) and my_level-application( ConstStr & "_l_kick")<0 then my_level=application( ConstStr & "_l_kick")
votes=application( ConstStr & "_votes")
if (votes(0)<>0 and votes(1)=myname) then my_level=1

selwho=request("selwho")
EXflag=false
Set Conn=Server.CreateObject("ADODB.Connection")
conn.open Application( ConstStr & "_connstr")
set rs=conn.execute("SELECT * FROM user WHERE username='" & selwho & "'")
if rs.eof or rs.bof then
   response.redirect("showerr.asp?errtext=<font color=336699>〖"&selwho&"〗</font>还没有注册呢！")
   response.end
else
  selwho=rs("username")
  towho_level=rs("user_level")
  if instr(" "&room_array2(12)&" "," "&selwho&" ")<>0 then EXflag=true
  if my_level-application( ConstStr & "_l_kick")<0 or myname=selwho or my_level-towho_level<=0 then
    response.redirect("userinfo.asp?name="&selwho)
    response.end
  end if
end if
forwhat=request("forwhat")%>

<HEAD>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<link rel="stylesheet" type="text/css" href="chat.css">
<script>function x(y,z){document.write("<option value=\""+y+"\">"+z+"</option>")}</script>
</HEAD>

<body style="background-color:EAF2FF;color:112233;scrollbar-Base-Color: #b0d8ff;SCROLLBAR-DARKSHADOW-COLOR:#b0d8ff;SCROLLBAR-arrow-COLOR:#336699;SCROLLBAR-TRACK-COLOR: EAF2FF;SCROLLBAR-3DLIGHT-COLOR: #b0d8ff;SCROLLBAR-SHADOW-COLOR: #336699;SCROLLBAR-HIGHLIGHT-COLOR: #b0d8ff;" topmargin=0px>
  <table height=100% width=100%><tr><td align=center valign=center >
  <table width=380 align=center cellspacing=0 cellpadding=0 border=1 BORDERCOLORLIGHT=#000000 BORDERCOLORDARK=#ffffff>
   <tr><td class=navy2>你会怎么对待聊友<font color=ffcc66>〖<%=selwho%>〗</font>？请输入理由！</td>
<%if EXflag then%>
  <form action=douser.asp method=post name=frmdo>
  <input name=selwho type=hidden value="<%=selwho%>">
  <tr><td height=65 nowrap><select name=list style="background-color:3399FF;color:FFFFFF"
    onchange="javascript:document.frmdo.forwhat.value=document.frmdo.list.value;document.frmdo.forwhat.focus();">
    <script>x("","踢人");x("讲脏话、怪话","脏话");x("乱发和重发一些毫无意义的言论","捣乱");
    x("使用HTML干扰他人聊天","HTML");x("名字不雅","名字");x("自己申请","申请");</script></select>　
    <input name=forwhat type=text maxlength=40  size=40 value="<%=forwhat%>">
  <br><br><input class=navy1 type=submit name=cmdYes value="踢人">
    <%if my_level-application( ConstStr & "_l_lockip")>=0 then%><input class=navy1 type=submit name=cmdYes value="封IP"><%end if%>
    <input class=navy1 type=reset name=cmdClear value=清除>
    <input class=navy1 type=button name=cmdCancel value=放弃 onClick="javascript:window.close()">
    </td></tr></form>
<%end if
if (true_level-application( ConstStr & "_l_modlevel")>=0 and towho_level<application( ConstStr & "_l_kick")-1 ) or true_level-application( ConstStr & "_superlevel")=0 then
  end_level=application( ConstStr & "_l_kick")
  if true_level-application( ConstStr & "_superlevel")=0 then end_level=true_level%>
  <form action=new_level.asp method=post name=frmlevel>
  <input name=selwho type=hidden value="<%=selwho%>">
  <tr><td height=65><select name=list style="background-color:3399FF;color:FFFFFF"
    onchange="javascript:document.frmlevel.forwhat.value=document.frmlevel.list.value;document.frmlevel.forwhat.focus();">
    <script>function a(b){var i;for (i=1;i<b;i++) {document.write("<option value=\""+i+"\">"+i+"级</option>")}};
    x("","升降");x("非常热心","热心");x("表现非常好","表现");x("滥用职权","职权");</script></select>　
    <input name=forwhat type=text maxlength=40  size=40 value="<%=forwhat%>">
  <br><br><select name=new_level style="background-color:3399FF;color:FFFFFF">
   <script>a(<%=end_level%>)</script></select><script>document.frmlevel.new_level.options[<%=(towho_level-1)%>].selected=true;</script>
    <input class=navy1 type=submit name=cmdYes value="修改级别">
    <input class=navy1 type=reset name=cmdClear value=清除>
    </td></tr></form>
<%end if
if (my_level-application( ConstStr & "_l_lockuser")>=0) then%>
  <form action=killuser.asp method=post name=frmkill>
  <input name=selwho type=hidden value="<%=selwho%>">
  <tr><td height=65><select name=list style="background-color:3399FF;color:FFFFFF"
    onchange="javascript:document.frmkill.forwhat.value=document.frmkill.list.value;document.frmkill.forwhat.focus();">
    <script>x("","冻结");x("表现十分恶劣","恶劣");x("在聊天室捣乱","捣乱");</script></select>　
    <input name=forwhat type=text maxlength=40  size=40 value="<%=forwhat%>">
  <br><br><input class=navy1 type=submit name=cmdYes value="冻结用户">
    <%if my_level-application( ConstStr & "_l_colduser")>=0 then%><input class=navy1 type=submit name=cmdYes value="永久冻结"><%end if%>
    <input class=navy1 type=reset name=cmdClear value=清除>
    </td></tr>
<%end if%>
</table><br>[<a href='userinfo.asp?name=<%=selwho%>'>聊友信息</a>] [<a href='javascript:history.go(-1)'>后退</a>]</td></tr></table></form></body>
<%
rs.close
set rs=nothing
conn.close
set conn=nothing%>