📄 jhchat.asp
字号:
<!--#include file="../config/config.asp"-->
<%Response.Buffer = true
Response.Expires= 0
scrname=Request.ServerVariables("SCRIPT_NAME")
if Instr(LCase(scrname),"jhchat.asp")=0 then Response.Redirect "../error.asp?id=002"
nickname=Session("hxf_u_nickname")
useronlinename=Application("hxf_c_useronlinename")
Session("hxf_u_sift")="0"
Session("hxf_u_filname")=" ,"
if nickname<>lyy and closedoor="yes" then Response.Redirect "../error.asp?id=100"
if nickname="" then Response.Redirect "../error.asp?id=210"
Set conn=Server.CreateObject("ADODB.CONNECTION")
Set rs=Server.CreateObject("ADODB.RecordSet")
connstr=Application("hg_connstr")
conn.open connstr
Sql="SELECT 状态,lastip,times FROM 用户 WHERE 姓名='" & nickname & "'"
rs.open sql,conn,1,1
zt=rs("状态")
if zt="" or zt="无" then Session.Abandon
rs.close
conn.close
set rs=nothing
set conn=nothing
n=Year(date())
y=Month(date())
r=Day(date())
s=Hour(time())
f=Minute(time())
m=Second(time())
if len(y)=1 then y="0" & y
if len(r)=1 then r="0" & r
if len(s)=1 then s="0" & s
if len(f)=1 then f="0" & f
if len(m)=1 then m="0" & m
sj=n & "-" & y & "-" & r & " " & s & ":" & f & ":" & m
t=s & ":" & f & ":" & m
Session("hxf_u_lastsaytime")=sj
if Session("hxf_u_inthechat")<>"1" then
if InStr(LCase(useronlinename)," " & LCase(nickname) & " ")<>0 then Response.Redirect "../error.asp?id=300"
Session("hxf_u_inthechat")="1"
Session("hxf_u_savetime")=sj
Session("hxf_u_lasttime")=sj
Application.Lock
onlinelist=Application("hxf_c_onlinelist")
dim newonlinelist()
useronlinename=""
onliners=0
js=1
yjl=0
ubl=UBound(onlinelist)
for i=1 to ubl step 6
if DateDiff("n",onlinelist(i+5),sj)<=60 then
if yjl=0 and StrComp(onlinelist(i+1),nickname,1)=1 then
yjl=1
onliners=onliners+2
useronlinename=useronlinename & " " & nickname & " " & onlinelist(i+1)
Redim Preserve newonlinelist(js),newonlinelist(js+1),newonlinelist(js+2),newonlinelist(js+3),newonlinelist(js+4),newonlinelist(js+5),newonlinelist(js+6),newonlinelist(js+7),newonlinelist(js+8),newonlinelist(js+9),newonlinelist(js+10),newonlinelist(js+11)
newonlinelist(js)=0
newonlinelist(js+1)=nickname
newonlinelist(js+2)=mysex
newonlinelist(js+3)=Session("mypai")
newonlinelist(js+4)=sj
newonlinelist(js+5)=sj
newonlinelist(js+6)=onlinelist(i)
newonlinelist(js+7)=onlinelist(i+1)
newonlinelist(js+8)=onlinelist(i+2)
newonlinelist(js+9)=onlinelist(i+3)
newonlinelist(js+10)=onlinelist(i+4)
newonlinelist(js+11)=onlinelist(i+5)
js=js+12
else
onliners=onliners+1
useronlinename=useronlinename & " " & onlinelist(i+1)
Redim Preserve newonlinelist(js),newonlinelist(js+1),newonlinelist(js+2),newonlinelist(js+3),newonlinelist(js+4),newonlinelist(js+5)
newonlinelist(js)=onlinelist(i)
newonlinelist(js+1)=onlinelist(i+1)
newonlinelist(js+2)=onlinelist(i+2)
newonlinelist(js+3)=onlinelist(i+3)
newonlinelist(js+4)=onlinelist(i+4)
newonlinelist(js+5)=onlinelist(i+5)
js=js+6
end if
end if
next
if yjl=0 then
onliners=onliners+1
useronlinename=useronlinename & " " & nickname
Redim Preserve newonlinelist(js),newonlinelist(js+1),newonlinelist(js+2),newonlinelist(js+3),newonlinelist(js+4),newonlinelist(js+5)
newonlinelist(js)=0
newonlinelist(js+1)=nickname
newonlinelist(js+2)=mysex
newonlinelist(js+3)=Session("mypai")
newonlinelist(js+4)=sj
newonlinelist(js+5)=sj
end if
useronlinename=useronlinename&" "
if onliners=0 then
dim listnull(0)
Application("hxf_c_onlinelist")=listnull
else
Application("hxf_c_onlinelist")=newonlinelist
end if
Application("hxf_c_useronlinename")=useronlinename
Application("hxf_c_chatrs")=onliners
sd=Application("hxf_c_sd")
line=int(Application("hxf_c_line"))
Application("hxf_c_line")=line+1
Session("hxf_u_line")=line-1
for i=1 to 171
sd(i)=sd(i+9)
next
sd(172)=line
sd(173)=1
sd(174)=0
sd(175)=nickname
sd(176)="大家"
sd(177)="660099"
sd(178)="660099"
sd(179)="对"
if Application("hxf_c_disnewuser")=1 or nickname<>lyy then
if tjf=true then tjc="<br><font color=red>【警戒】通缉犯<b>[<a href=javascript:parent.sw('[" & nickname & "]'); target=f2>" & nickname & "</a>]</b>偷偷的爬进江湖,请大家进入一级戒备状态!</font><font class=t>(" & t & ")</font><br><font color=red><b>【官府令】杀死通缉犯["& nickname & "]将得到白银200万重赏,道德上升1000,大家快点围剿啊!</b></font>"
sd(180)="<font color=black>〖欢迎〗</font><font color=008800>" & Replace(userinto,"%%","<a href=javascript:parent.sw('[" & nickname & "]'); target=f2><img border='0' src='../"&txxx&"'>" & nickname & "</a>") & "</font><font class=t>(" & t & ")</font><bgsound src='readonly/cd.mid' loop='1'>"&tjc
else
sd(180)=""
end if
Application("hxf_c_sd")=sd
Application.UnLock
end if
%>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<style>BODY{background-position:'top right';background-repeat: no-repeat;background-attachment: fixed;}\n");</style>
<script Language="Javascript">
if(window!=window.top)
{
window.alert("请用IE浏览器使用本系统!");
top.location.href="../exit.asp"
}
if(window.name!="woiwo")
{ var i=1;
while (i<=50)
{
window.alert("去别处玩去这个去吧,我这里可不允许哟!你慢慢点50次吧,哈哈!!");
i=i+1;
}
top.location.href="../exit.asp"
}
var crm="<%=chatroomname%>";
var bgc="#EEEEEE";
var myn='<%=nickname%>';
var cs=<%=Session("hxf_u_grade")%>;
var lst=0;
var tbclu=true;document.write("<title>"+crm+"</title>");
function write(cls)
{var fsize,lheight;
if(cls==1)
{fsize=this.f2.document.af.fs.value;lheight=this.f2.document.af.lh.value;}
else{fsize='10.5';lheight='125';}
this.f1.document.open();
this.f1.document.writeln("<html><head><title>对话区</title><meta http-equiv=Content-Type content=\"text/html; charset=gb2312\">");
this.f1.document.writeln("<style type=text/css>.p{font-size:20pt}.l{line-height:" + lheight + "%}.t{color:FF00FF;font-size:9pt;}body{font-family:\"宋体\";font-size:" + fsize + "pt}A{text-decoration:none}A:Hover{text-decoration:underline}A:visited{color:blue}</style></head><\Script Language=\"JavaScript1.1\">");
this.f1.document.writeln("var autoScrollOn=1;var scrollOnFunction;var scrollOffFunction;");
this.f1.document.writeln("function scrollit(){if(!parent.f2.document.af.as.checked){autoScrollOn=0;return true;}else{autoScrollOn=1;StartUp();return true;}}function scrollWindow(){if(autoScrollOn==1){this.scroll(0,65000);parent.f0.scroll(0,65000);setTimeout('scrollWindow()',200);}}function scrollOn(){autoScrollOn=1;scrollWindow();}function scrollOff(){autoScrollOn=0;}function StartUp(){this.onblur=scrollOnFunction;this.onfocus=scrollOffFunction;scrollWindow();}");
this.f1.document.writeln("scrollOnFunction=new Function('scrollOn()');");
this.f1.document.writeln("scrollOffFunction=new Function('scrollOff()');");
this.f1.document.writeln("StartUp();</\script>");
this.f1.document.writeln("<style type='text/css'>BODY{background-position:'top right';background-repeat: no-repeat;background-attachment: fixed;});</style>");
this.f1.document.writeln("<body oncontextmenu=self.event.returnValue=false bgcolor=" + bgc + " text=660099>");
this.f1.document.writeln("<span class=l><font color=red>【刷新】</font>欢迎<font color=red>〖"+myn+"〗</font>来到『"+crm+"』!<font class=t>(<%=t%>)</font></span><br>");
this.f0.document.open();this.f0.document.writeln("<html><head><title>分屏显示</title><meta http-equiv=Content-Type content=\"text/html; charset=gb2312\">");
this.f0.document.writeln("<style type=text/css>.p{font-size:20pt}.l{line-height:" + lheight + "%}.t{color:FF00FF;font-size:9pt;}body{font-family:\"宋体\";font-size:" + fsize + "pt;}A{text-decoration:none}A:Hover{text-decoration:underline}A:visited{color:blue}</style></head>");
this.f0.document.writeln("<body oncontextmenu=self.event.returnValue=false bgcolor=" + bgc + " text=660099>");
this.f0.document.writeln("<span class=l><font color=red>【刷新】</font>欢迎<font color=red>〖"+myn+"〗</font>来到『"+crm+"』!<font class=t>(<%=t%>)</font></span><br>");
this.t.location.href="t.asp";}
function sh(ac,mm,n1,n2,y1,y2,bq,ll)
{var show;
if(ac==1)
{if(mm==1){show="<span class=l>【私聊】"+ll+"</span><br>";}
else{show="<span class=l>"+ll+"</span><br>";}}
else{if(mm==1){show="<span class=l>【私聊】";}
else{show="<span class=l>";}
if(n1==myn){show=show+"<a href=javascript:parent.sw('["+n1+"]'); target=f2><font color="+y1+"><b>"+n1+"</b></font></a>"+bq;}
else{show=show+"<a href=javascript:parent.sw('["+n1+"]'); target=f2><font color="+y1+">"+n1+"</font></a>"+bq;}
if(n2==myn){show=show+"<font color=red>〖<a href=javascript:parent.sw('["+n2+"]'); target=f2><font color=red>"+n2+"</font></a>〗</font>";}
else{show=show+"<a href=javascript:parent.sw('["+n2+"]'); target=f2><font color=660099>"+n2+"</font></a>";}show=show+"说:"+"<font color="+y2+">"+ll+"</font></span><br>";}
if(tbclu==true & (myn==n1 | myn==n2)){this.f1.document.writeln(show);}
else{this.f0.document.writeln(show);}}
function chatbg(bg){
bgc=bg;
this.f0.location.href="about:blank";
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -