View Full Version : Hottest Threads!
Sharif
01-03-2005, 08:12 PM
Is there any way I can make a mysql query where I can get like the 3 most popular threads on the forum? And list it like this:
- Thread Title (x Posts)
- Thread Title (x Posts)
- Thread Title (x Posts)
?
I am running Vb 3.0.4.
Dean C
01-03-2005, 08:39 PM
What do you mean? The three threads on the forum that have the most replies?
Sharif
01-03-2005, 09:29 PM
The three most ACTIVE threads! I guess the three with the latest replies will do too.
Dean C
01-03-2005, 10:03 PM
By latest how do you mean? What would you define a timespan as latest for? The last day? The last week? The last month? :)
Sharif
01-03-2005, 10:53 PM
Latest I mean with the threads that has the most recent posts. Like as soon as I make this post, this thread will have the most recent post... get it?
You should look around. It's already been done. Search for "latest threads" or something along that line.
Dean C
01-04-2005, 11:12 AM
Ah yes getting the last x posts has been asked many times before. You had me confused for a while there ;) Do a search and ye shall find.
Sharif
01-04-2005, 07:03 PM
I did a search a few mins back and it seems no one ever posted a solution for vb3 yet... a lot of questions, no answers.
Link14716
01-04-2005, 07:35 PM
The three with the most replies:
SELECT * FROM thread ORDER BY replycount DESC LIMIT 3
The three with the most views:
SELECT * FROM thread ORDER BY views DESC LIMIT 3
The three latest updated threads:
SELECT * FROM thread ORDER BY lastpost DESC LIMIT 3
Sharif
01-04-2005, 08:12 PM
Which would you consider to be used to show the most POPULAR? Views or replies?
vBulletin® v3.8.12 by vBS, Copyright ©2000-2025, vBulletin Solutions Inc.