Log Display

<% Dim fso Dim tf Dim line Dim parts Set fso = CreateObject("Scripting.FileSystemObject") Set tf = fso.OpenTextFile("C:\WINNT\System32\LogFiles\W3SVC1\ex" & Request("date") & ".log", 1) tf.SkipLine tf.SkipLine tf.SkipLine tf.SkipLine %> ">Not filtered &filter=1">Only 1xx status &filter=2">Only 2xx status &filter=3">Only 3xx status &filter=4">Only 4xx status &filter=5">Only 5xx status <% Do While Not tf.AtEndOfStream line = tf.ReadLine parts = Split(line, " ") if UBound(parts) = 4 Then If Request("filter") = "" Or CStr(CInt(Parts(4)/100)) = Request("filter") Then If Parts(4) = 200 Then %> <% Else %> <% End If %> <% End If End If Loop tf.Close %>
Time Remote Host Method Path Status
<%=parts(0)%> <%=parts(1)%> <%=parts(2)%> <%=parts(3)%> <%=parts(4)%>