Features:
-showing lastposts at forum tables
-if the last post belongs a subforum, shows it ( you know the original default.asp file does not show subforums' last posts)
-correcting subforum variables that not shown under topics, posts in forum tables (topic nums, post nums etc...)
-at the bottom (in statistics area) showing correct informations. (last posted user etc..)
caps:

< =text/>setImgWidth();
the red codes are modified or added codes by me, open your default.asp file and follow the steps...
1-add dim fsub variable at the bottom of dim rows
Dim intBirtdayLoopCounter 'Holds the bitrhday loop counter dim strSubject dim fsub
|
2-add fsub = 0 code under strSubForums = ""
Do While intCurrentRecord <= Ubound(sarryForums,2) 'Initialise variables strSubForums = "" fsub = 0
|
3-replace intCurrentRecord code with intTempRecord
strLastSubEntryUser = sarryForums(8,intTempRecord) If isNumeric(sarryForums(9,intTempRecord)) Then lngLastSubEntryUserID = CLng(sarryForums(9,intTempRecord)) Else lngLastEntryUserID = 0 If isDate(sarryForums(10,intTempRecord)) Then dtmLastSubEntryDate = CDate(sarryForums(10,intTempRecord)) Else dtmLastSubEntryDate = Now()
|
4-copy the red codes and paste under the black codes
'Add all the posts and topics together to get the total number for the stats at the bottom of the page lngTotalNumberOfPosts = lngTotalNumberOfPosts + lngSubForumNumberOfPosts lngTotalNumberOfTopics = lngTotalNumberOfTopics + lngSubForumNumberOfTopics lngNumberOfPosts = lngNumberOfPosts + lngSubForumNumberOfPosts lngNumberOfTopics = lngNumberOfTopics + lngSubForumNumberOfTopics
If dtmLastEntryDateAllForums < dtmLastSubEntryDate Then strLastEntryUserAllForums = strLastSubEntryUser lngLastEntryUserIDAllForums = lngLastSubEntryUserID dtmLastEntryDateAllForums = dtmLastSubEntryDate End If If dtmLastEntryDate < dtmLastSubEntryDate Then dtmLastEntryDate = dtmLastSubEntryDate lngLastEntryUserID = lngLastSubEntryUserID strLastEntryUser = strLastSubEntryUser fsub= intsubforumid End If 'If there are other sub forums place a comma inbetween If strSubForums <> "" Then strSubForums = strSubForums & ", " |
5-copy the red codes and paste between black codes
'Write the HTML of the forum descriptions and hyperlinks to the forums 'Son mesajlar strSQL = "SELECT" & strDBTop1 & " " & strDbTable & "Topic.Subject FROM " & strDbTable & "Topic" & strDBNoLock & ", " & strDbTable & "Thread" & strDBNoLock & " " & _ "WHERE " & strDbTable & "Topic.Topic_ID = " & strDbTable & "Thread.Topic_ID AND " & strDbTable & "Topic.Forum_ID=" & fsub & " AND " & strDbTable & "Topic.Hide=" & strDBFalse & " " & _ "AND " & strDbTable & "Thread.Hide=" & strDBFalse & " ORDER BY " & strDbTable & "Thread.Message_date DESC" & strDBLimit1 & ";" rsCommon.Open strSQL, adoCon
if fsub = 0 then fsub = intforumid if NOT rsCommon.EOF then If len(rsCommon("Subject"))>50 Then strSubject = "<a href=""get_last_post.asp?FID=" &fsub & """ style=""font-size:11px; font-weight : bold; color : #465584;"">" & left(rsCommon("Subject"),50) &"..."& "</a>" else strSubject = "<a href=""get_last_post.asp?FID=" &fsub & """ style=""font-size:11px; font-weight : bold; color : #465584;"">" & rsCommon("Subject")& "</a>" End If end if rsCommon.Close 'Son Mesajlar 'Calculate row colour |
6-replace original code with the red code in your default page
[quote]
'Display forum details
Response.Write("<br /><span style=""font-size:11px;"">" & strForumDiscription & strSubForums & "</span></td>" & _
vbCrLf & " <td align=""center"">" & lngNumberOfTopics & "</td>" & _
vbCrLf & " <td align=""center"">" & lngNumberOfPosts & "</td>" & _
vbCrLf & " <td class=""smText"" align=""right"" nowrap>")