Author |
Topic |
|
Immanuel
New Member
64 Posts |
Posted - 30 August 2002 : 14:21:24
|
I hope i placed it right this time. This is a bug report. When I am not logged in to my forum, Ican get a message like this:
"There are currently 4 topics and 6 active topics since you last visited."
in the low part of the page with the statistics. That is a bit odd, isn't it?
For reference my page is www.kuhrt.dk/samplitude and I use 3.4.01 with all but the last single bug fix applied. I have installed the stylechanger mod.
Immanuel |
|
RichardKinser
Snitz Forums Admin
USA
16655 Posts |
Posted - 30 August 2002 : 14:32:39
|
what does it show when you are logged in? |
|
|
pweighill
Junior Member
United Kingdom
453 Posts |
Posted - 30 August 2002 : 15:38:44
|
It's probably due to hideden/private forums.
One suggestion to change this is to edit default.asp and change:
'## Forum_SQL - Get ActiveTopicCount from DB
strSql = "SELECT COUNT(" & strTablePrefix & "TOPICS.T_LAST_POST) AS NUM_ACTIVE " &_
" FROM " & strTablePrefix & "TOPICS " &_
" WHERE (((" & strTablePrefix & "TOPICS.T_LAST_POST)>'"& Session(strCookieURL & "last_here_date") & "'))" &_
" AND " & strTablePrefix & "TOPICS.T_STATUS <= 1"
to
'## Forum_SQL - Get ActiveTopicCount from DB
strSql = "SELECT COUNT(T.T_LAST_POST) AS NUM_ACTIVE " &_
" FROM " & strTablePrefix & "TOPICS T, " & strTablePrefix & "FORUM F," &_
" WHERE F.FORUM_ID=T.FORUM_ID" &_
" AND T.T_LAST_POST>'"& Session(strCookieURL & "last_here_date") & "'" &_
" AND T.T_STATUS <= 1" &_
" AND F.F_PRIVATEFORUMS = 0"
and it would then always ignore these forums in the activetopic count.
It might then undercount in some situations but undercounting is less noticable tham the overcounting in this case. |
|
|
D3mon
Senior Member
United Kingdom
1685 Posts |
|
Immanuel
New Member
64 Posts |
Posted - 31 August 2002 : 14:23:47
|
Now it is: There are currently 6 topics and 8 active topics since you last visited. There is one topic in one hidden forum (and it has not been touched since last visit).
After logging in it says: There are currently 7 topics and 2 active topics since you last visited.
After logging out it says: There are currently 6 topics and 8 active topics since you last visited. again.
I updated the page before logging in and after logging in and after logging out, so that is not the reason.
Immanuel
|
|
|
Immanuel
New Member
64 Posts |
Posted - 31 August 2002 : 14:33:27
|
I did a reply to the topic in the hidden forum with my admin account with Opera, but my test account with IE6 (IE=international error) still says: There are currently 6 topics and 8 active topics since you last visited. - also after a page update.
Immanuel |
|
|
RichardKinser
Snitz Forums Admin
USA
16655 Posts |
Posted - 31 August 2002 : 18:08:02
|
If there are hidden forums, then it should not even be showing the Active count at all. If you logout on this forum, you'll see what I mean. It shows the Total Topic Count, but that's it. |
|
|
RichardKinser
Snitz Forums Admin
USA
16655 Posts |
Posted - 31 August 2002 : 18:12:22
|
looks like this might be the culprit:
blnHiddenForums = false
It's within the for/next loop for the Categories. So, if the first Category had a hidden forum, but the last category didn't, then the value would be false, even though it should be true. Probably need to move it out of the for/next loop for the Categories.
|
|
|
RichardKinser
Snitz Forums Admin
USA
16655 Posts |
Posted - 01 September 2002 : 05:37:25
|
fixed in v3.4.02 |
|
|
GenerationEdge
Junior Member
105 Posts |
Posted - 01 September 2002 : 11:39:46
|
quote: Originally posted by pweighill
It's probably due to hideden/private forums.
One suggestion to change this is to edit default.asp and change:
'## Forum_SQL - Get ActiveTopicCount from DB
strSql = "SELECT COUNT(" & strTablePrefix & "TOPICS.T_LAST_POST) AS NUM_ACTIVE " &_
" FROM " & strTablePrefix & "TOPICS " &_
" WHERE (((" & strTablePrefix & "TOPICS.T_LAST_POST)>'"& Session(strCookieURL & "last_here_date") & "'))" &_
" AND " & strTablePrefix & "TOPICS.T_STATUS <= 1"
to
'## Forum_SQL - Get ActiveTopicCount from DB
strSql = "SELECT COUNT(T.T_LAST_POST) AS NUM_ACTIVE " &_
" FROM " & strTablePrefix & "TOPICS T, " & strTablePrefix & "FORUM F," &_
" WHERE F.FORUM_ID=T.FORUM_ID" &_
" AND T.T_LAST_POST>'"& Session(strCookieURL & "last_here_date") & "'" &_
" AND T.T_STATUS <= 1" &_
" AND F.F_PRIVATEFORUMS = 0"
and it would then always ignore these forums in the activetopic count.
It might then undercount in some situations but undercounting is less noticable tham the overcounting in this case.
When I changed this on a fresh set of .01 files and run the setup.asp and then said "installation complete", "go to forums". When Opening the default.asp it flagged an error above the board table. It stated syntax error in line #875. I wish I would have looked at the error closer to tell you what the exact verbage was but I removed the code you added to default.asp and went back to the previous one and then it worked. |
Jason |
|
|
Therion93
Junior Member
USA
263 Posts |
Posted - 01 September 2002 : 13:19:02
|
Ok I found that statement but where should I move it to? |
|
|
MichaelA
Junior Member
USA
222 Posts |
Posted - 01 September 2002 : 13:25:22
|
quote: Originally posted by RichardKinser
looks like this might be the culprit:
blnHiddenForums = false
It's within the for/next loop for the Categories. So, if the first Category had a hidden forum, but the last category didn't, then the value would be false, even though it should be true. Probably need to move it out of the for/next loop for the Categories.
Richard,
Should only this last fix be applied or the one in a previous message above, or both.
Thanks.
Mike
|
|
|
RichardKinser
Snitz Forums Admin
USA
16655 Posts |
Posted - 01 September 2002 : 14:27:21
|
The fix is this:
on line #408 find the following:
blnHiddenForums = false
move that line of code to line #372, right above this line:
for iCategory = 0 to recCategoryCount
|
|
|
|
Topic |
|