<!--#include file="../Inc.asp"-->
<!--#include file="../ydzq.asp"-->
<!--#include file="../forbbs.asp"-->
<%



call head()


Call FortxtChat
Call saycardd("发送聊天邀请")

dim ID,user,IDS
ID=trim(Request.QueryString("ID"))
IDS=trim(Request.QueryString("IDS"))
if ID="" or IsNumeric(ID)=false then
   Call Error("错误的聊天室ID")
end if
if IDS<>"" then
if IDS="" or IsNumeric(IDS)=false then
   Call Error("会员ID无效")
end if

dim reuser
set rs=server.createobject("ADODB.Recordset")
rs.Open "select ID,name from Users where ID = "&IDS,conn,1,1
if not rs.eof then
user=rs("name")
reuser=1
end if
rs.close
set rs=nothing
end if
if saytk<>1 then
Response.write "<form name=""form"" method=""post"" action=""inviteallsave.asp?sid="&sid&"&amp;saytk="&saytk&""">"
end if
Response.write "<onevent type=""onenterforward"">"&chr(13)
Response.write "<refresh>"&chr(13)
Response.write "<setvar name=""Chat"" value=''/>"&chr(13)
Response.write "</refresh>"&chr(13)
Response.write "</onevent>"&chr(13)

Response.write "<p>"
Response.write "选择表情:"
response.write "<select title='表情' name='face' value='0'>"&chr(13)
response.write "<option title='表情' value='0'>表情</option>"&chr(13)
response.write "<option title='微笑' value='1'>微笑</option>"&chr(13)
response.write "<option title='哭泣' value='2'>哭泣</option>"&chr(13)
response.write "<option title='调皮' value='3'>调皮</option>"&chr(13)
response.write "<option title='脸红' value='4'>脸红</option>"&chr(13)
response.write "<option title='害羞' value='5'>害羞</option>"&chr(13)
response.write "<option title='生气' value='6'>生气</option>"&chr(13)
response.write "<option title='偷笑' value='7'>偷笑</option>"&chr(13)
response.write "<option title='流汗' value='8'>流汗</option>"&chr(13)
response.write "<option title='我倒' value='9'>我倒</option>"&chr(13)
response.write "<option title='得意' value='10'>得意</option>"&chr(13)
response.write "<option title='眦牙' value='11'>眦牙</option>"&chr(13)
response.write "<option title='疑问' value='12'>疑问</option>"&chr(13)
response.write "<option title='睡觉' value='13'>睡觉</option>"&chr(13)
response.write "<option title='好色' value='14'>好色</option>"&chr(13)
response.write "<option title='口水' value='15'>口水</option>"&chr(13)
response.write "<option title='敲头' value='16'>敲头</option>"&chr(13)
response.write "<option title='可爱' value='17'>可爱</option>"&chr(13)
response.write "<option title='猪头' value='18'>猪头</option>"&chr(13)
response.write "<option title='YEAH' value='19'>YEAH</option>"&chr(13)
response.write "<option title='玫瑰' value='20'>玫瑰</option>"&chr(13)
response.write "</select>"&chr(13)
response.write "<br/>附言内容<input type=""text"" name=""reContent""/>"&chr(13)
if saytk<>1 then
response.write "<input type=""hidden"" name=""id"" value="""&id&"""/>"
response.write "<input type=""submit"" name=""Submit"" value=""群发好友""></form><br/>"
else
Response.write "<br/><anchor>[群发好友]"&chr(13)
Response.write "<go href=""inviteallsave.asp?sid="&sid&"&amp;saytk="&saytk&""" method=""post"">"&chr(13)
Response.write "<postfield name=""id"" value="""&id&"""/>"&chr(13)
Response.write "<postfield name=""face"" value=""$(face)""/>"&chr(13)
Response.write "<postfield name=""reContent"" value=""$(reContent)""/>"&chr(13)
Response.write "</go></anchor>"&chr(13)
end if
if saytk<>1 then
Response.write "<form name=""form"" method=""post"" action=""inviteallsave.asp?sid="&sid&"&amp;saytk="&saytk&""">"
end if
response.write "<br/><select name='friendid' value=''><option value='0'>或选择好友</option>"

dim objgbrs,friendid,reusername
 set objgbrs=Server.CreateObject("ADODB.Recordset")
  objgbrs.open"select * from myfriend where cid="&myid&" order by id desc",conn,1,3
dim j
j=1
do while not objgbrs.eof
friendid=objgbrs("did")
set rs=server.createobject("ADODB.Recordset")
rs.Open "select ID,name from Users where ID = "&friendid,conn,1,1
if not rs.eof then
reusername=rs("name")
end if
rs.close
set rs=nothing
if len(reusername)>8 then reusername=left(reusername,8)
Response.write "<option value='"&ubb(friendid)&"'>" & ubb(reusername) & "</option>"
j=j+1
objgbrs.movenext
loop
objgbrs.close
set objgbrs=nothing
conn.close
set conn=Nothing
Response.write "</select>"
if saytk<>1 then
response.write "<input type=""hidden"" name=""id"" value="""&id&"""/>"
response.write "<input type=""submit"" name=""Submit"" value=""发送邀请""></form><br/>"
else
Response.write "<br/><anchor>[发送邀请]"&chr(13)
Response.write "<go href=""invitesave.asp?sid="&sid&"&amp;saytk="&saytk&""" method=""post"">"&chr(13)
Response.write "<postfield name=""id"" value="""&id&"""/>"&chr(13)
Response.write "<postfield name=""face"" value=""$(face)""/>"&chr(13)
Response.write "<postfield name=""friendid"" value=""$(friendid)""/>"&chr(13)
Response.write "<postfield name=""reContent"" value=""$(reContent)""/>"&chr(13)
Response.write "</go></anchor>"&chr(13)
end if
Response.write "<br/><a href=""chatroom.asp?ID="&ID&"&amp;sid="&sid&"&amp;saytk="&saytk&""">[返回房间]</a><br/>"&chr(13)
call headsay()
%>