// GLOBAL.ASA
<SCRIPT LANGUAGE=VBScript RUNAT=Server>
Sub Application_OnStart
Application("Ziyaretciler") = 0
End Sub
Sub Session_OnStart
Session.Timeout = 10
Session("Start") = Now
Session("Uye_Adi") = Request.Cookie("Snitz00User")("name")
If Session("name") = "" Then
Session("name") = "Misafir"
End If
If Not InStr(Application("Aktif_Uyeler"), Session("name")) Then
Application.Lock
Application("Aktif_Uyeler") = Application("Aktif_Uyeler") & Session("name") & "||"
Application.UnLock
End If
Application.Lock
Application("Ziyaretciler") = Application("Ziyaretciler") + 1
Application.UnLock
End Sub
Sub Session_OnEnd
If Len(Session("name")) > 0 Then
Application.Lock
Application("Aktif_Uyeler") = Replace(Application("Aktif_Uyeler"), Session("name") & "||", "")
Application.UnLock
End If
Application.Lock
Application("Ziyaretciler") = Application("Ziyaretciler") - 1
Application.UnLock
Session("name") = ""
End Sub
</SCRIPT>
// online.asp
<%
arr_Uyeler = Split(Application("Aktif_Uyeler" ), "||" )
For i = 0 To Ubound(arr_Uyeler) - 1
If arr_Uyeler(i) <> "Misafir" Then
End If %>
<table width="94%" border="0" align="center">
<tr>
<td><font face="Tahoma" color="#000000" size="2"><b><li><%= arr_Uyeler(i) %>
</b></font></td>
</tr>
</table>
<%
Next
%>
<br>
<br>