Snitz Forums 2000
Snitz Forums 2000
Home | Profile | Register | Active Topics | Members | Search | FAQ
Username:
Password:
Save Password
Forgot your Password?

 All Forums
 Snitz Forums 2000 DEV-Group
 DEV Bug Reports (Closed)
 (v3.4.01) BUG+FIX: default.asp
 Forum Locked  Topic Locked
 Printer Friendly
Author Previous Topic Topic Next Topic  

Immanuel
New Member

64 Posts

Posted - 30 August 2002 :  14:21:24  Show Profile  Visit Immanuel's Homepage
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  Show Profile
what does it show when you are logged in?
Go to Top of Page

pweighill
Junior Member

United Kingdom
453 Posts

Posted - 30 August 2002 :  15:38:44  Show Profile
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.
Go to Top of Page

D3mon
Senior Member

United Kingdom
1685 Posts

Posted - 30 August 2002 :  19:09:57  Show Profile  Visit D3mon's Homepage
To me that says:
10 topics in total - 6 of them are active.


Snitz 'Speedball' : Site Integration Mod : Friendly Registration Mod
"In war, the victorious strategist only seeks battle after the victory has been won"
Go to Top of Page

Immanuel
New Member

64 Posts

Posted - 31 August 2002 :  14:23:47  Show Profile  Visit Immanuel's Homepage
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
Go to Top of Page

Immanuel
New Member

64 Posts

Posted - 31 August 2002 :  14:33:27  Show Profile  Visit Immanuel's Homepage
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
Go to Top of Page

RichardKinser
Snitz Forums Admin

USA
16655 Posts

Posted - 31 August 2002 :  18:08:02  Show Profile
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.
Go to Top of Page

RichardKinser
Snitz Forums Admin

USA
16655 Posts

Posted - 31 August 2002 :  18:12:22  Show Profile
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.
Go to Top of Page

RichardKinser
Snitz Forums Admin

USA
16655 Posts

Posted - 01 September 2002 :  05:37:25  Show Profile
fixed in v3.4.02
Go to Top of Page

GenerationEdge
Junior Member

105 Posts

Posted - 01 September 2002 :  11:39:46  Show Profile
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
Go to Top of Page

Therion93
Junior Member

USA
263 Posts

Posted - 01 September 2002 :  13:19:02  Show Profile  Send Therion93 an ICQ Message
Ok I found that statement but where should I move it to?
Go to Top of Page

MichaelA
Junior Member

USA
222 Posts

Posted - 01 September 2002 :  13:25:22  Show Profile
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
Go to Top of Page

RichardKinser
Snitz Forums Admin

USA
16655 Posts

Posted - 01 September 2002 :  14:27:21  Show Profile
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

Go to Top of Page
  Previous Topic Topic Next Topic  
 Forum Locked  Topic Locked
 Printer Friendly
Jump To:
Snitz Forums 2000 © 2000-2021 Snitz™ Communications Go To Top Of Page
This page was generated in 0.22 seconds. Powered By: Snitz Forums 2000 Version 3.4.07