%
Set myConn = Server.CreateObject("ADODB.Connection")
myConn.Open strDSN
count = 0
strSQL = "SELECT *, DATE_FORMAT(date,'%d-%m-%Y') AS FormDate, TIME_FORMAT(date,'%H:%i') AS FormTime FROM Entries ORDER BY ID DESC"
Set rs = myConn.Execute(strSQL)
If Not (rs.BOF Or rs.EOF) Then
Do While ((Not rs.EOF) And count <10)
strSQL = "SELECT *, DATE_FORMAT(date,'%d-%m-%Y') AS FormDate, TIME_FORMAT(date,'%H:%i') AS FormTime FROM Entries WHERE (ReplyID =" & rs("Id") & ") AND (OrgThread = 0) ORDER BY ID DESC"
strComment = Replace(Replace(Server.HTMLEncode(rs("Comment")),"<","-"),">","-")
strSQL = "SELECT Count(*) AS ItemCount FROM Entries WHERE (ReplyID = " & rs("Id") & ") AND (orgthread <> 1)"
Set recordCount = myConn.Execute(strSQL)
' Vi viser ikke det hemelige forum hvis brugeren er medlem af SPO
If rs("ForumId") = 14 Then
Else
strHTML = strHTML & "(" & rs("ID") & ") " & Server.HTMLEncode(rs("Subject")) & " - " & rs("Name") & ""
strHTML = strHTML & "(" & rs("Date") & ") - " & strComment & ""
strHTML = strHTML & "" & rs("Date") & ""
End if
count = count + 1
rs.MoveNext
Loop
End If
myConn.Close
Set myConn = Nothing
'If InStr(Request.ServerVariables("HTTP_ACCEPT"), "application/xhtml+xml") > 0 Then
Response.ContentType = "application/xml"
'Else
' Response.ContentType = "text/html; charset=iso-8859-1"
'End If
Response.Charset = "iso-8859-1"
%>
SPO Forum
http://www.stolpaaos.dk/forum/
StolPaaOs.dk's forum
<%=strHTML%>