⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 ref.asp

📁 asp的web在线聊天室源程序,程序实现了聊天室的许多功能,特别是刷新功能,做到了实时刷新(有人说话才刷,保持.zip
💻 ASP
字号:

<html>

<head>
<SCRIPT LANGUAGE="VBScript">
<!--

sub senform()
 Dim TheForm
 Set TheForm = Document.ValidForm
 theform.action="liaotian.asp"
 TheForm.target="main"
 theform.submit()
end sub
sub senform1()
 Dim TheForm
 Set TheForm = Document.ValidForm
 theform.action="atline.asp"
 TheForm.target="atline"
 theform.submit()
end sub
sub senform2()
 Dim TheForm
 Set TheForm = Document.ValidForm
 theform.action="fp.asp"
 TheForm.target="fp"
 theform.submit()
end sub
-->
</SCRIPT>
</head>

<meta http-equiv="refresh" content="1; url='/liaotian/ref.asp'">
<body>
<form name="ValidForm" method="post" >   
  
  <p><input type="text" name="T1" size="20"><input type="submit" value="提交" name="B1"><input type="reset" value="全部重写" name="B2"></p>
</form>

<%
t=session("tim")
 strcnn="provider=Microsoft.Jet.OLEDB.4.0;Data source=" & server.MapPath("liaotian.mdb")
  set conn=server.CreateObject("ADODB.Connection")
  conn.open strCnn
  set rst=server.CreateObject("ADODB.Recordset")
  rst.open"select count(发言人) from liao ",strcnn,1,3
  
 if rst.eof=true then 

 else %>
 <p><%=rst.Fields(0)%> ggg <%=session("count")%></p>
 <%
if session("count")=0 then
   session("count")=rst.Fields(0)
end if
if  session("count")< rst.Fields(0) then   
%>
<SCRIPT LANGUAGE="VBScript">  
<!--  
 call senform()
-->  
</SCRIPT> 
          
<%
   
    session("count")=rst.Fields(0)  
    rst.Close 
 
  if session("fp")="yes" then
  
 rst.open"select  count(发言人) from liao where  时间 >= '" & t & "' and (发言人='" & trim(session("nam1")) & "' or 对话人='"& trim(session("nam1")) & "' or 对话人='大家') " ,strcnn
 
    if session("me")< rst.Fields(0) then
     session("me")= rst.Fields(0)
      %>
      <SCRIPT LANGUAGE="VBScript">  
       <!--  
         call senform2()
      -->  
        </SCRIPT> 
          <%
      end if
   end if       
end if

if Application("N")<>session("atline") then 
 session("atline")=Application("N")

  %>
  <script language="vbscript">
  <!--
   call senform1()
   -->
   </script>
 <%end if  
conn.Close 
set conn=nothing
rst.Close 
set rst=nothing
      
end if
 %>
</body>

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -