<%@Language = "VBScript"%> <% Option Explicit Response.Buffer = True Response.Expires = -1000 Dim vRoomNo vRoomNo = Session("RoomNo") GetNewLines CLng(Session("LastLine")) Response.Flush Response.End Sub GetNewLines(byVal vLastLine) Dim vCurrentLine, vChatLines Dim vNewLines, vLine, vLineText Dim vPrivatePrefix vPrivatePrefix = "/msg " & Session("ChatName") & " " vCurrentLine = Application("ChatLineCount" & vRoomNo) vChatLines = Application("ChatLines" & vRoomNo) For vLine = vLastLine To vCurrentLine - 1 vLineText = vChatLines(vLine) If Instr(vLineText, "/msg ") = 1 Then If Instr(vLineText, vPrivatePrefix) = 1 Then vNewLines = vNewLines & "[Private] " & Right(vLineText, Len(vLineText) - Len(vPrivatePrefix)) & Chr(13) End If Else vNewLines = vNewLines & vLineText & Chr(13) End If Next Session("LastLine") = vCurrentLine Response.Write "NewLines=" & Server.URLEncode(vNewLines) & "&Result=OK" End Sub %>