Xmlhttp+javascript+asp Write chat room, no refresh implementation. Original code to broadcast! The server supports ASP, which is
Source: Internet
Author: User
############### #reload. asp##############
<% ' response.contenttype= "Text/xml"
Response.Write "<?xml version=" "1.0" "encoding=" "GB2312" "?>"
Response.Write "<Msg>"
Dim c_info,c_lid,c_ip,u_lid,newlid,u_name,i
C_info=application ("C_info")
U_lid=session ("U_lid")
Newlid=u_lid
U_name= "Netnice"
For I=c_info (0) +6 to 6
if (C_info (i) >u_lid) and (C_info (i+1) =u_name) or (C_info (i+2) =u_name) or (C_info (i+2) = "Everyone") or (C_info (i+3) = "0")) Then
Response.Write C_info (i+5)
if (Newlid<c_info (i)) then Newlid=c_info (i)
End If
Next
For I=1 to C_info (0) Step 6
if (C_info (i) >u_lid) and (C_info (i+1) =u_name) or (C_info (i+2) =u_name) or (C_info (i+2) = "Everyone") or (C_info (i+3) = "0")) Then
Response.Write C_info (i+5)
if (Newlid<c_info (i)) then Newlid=c_info (i)
End If
Next
Response.Write "</Msg>"
Session ("U_lid") =newlid
%>
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.
A Free Trial That Lets You Build Big!
Start building with 50+ products and up to 12 months usage for Elastic Compute Service