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

 All Forums
 Help Groups for Snitz Forums 2000 Users
 Help: General / Classic ASP versions(v3.4.XX)
 Sort by popularity?
 New Topic  Topic Locked
 Printer Friendly
Author Previous Topic Topic Next Topic  

davidkirk
Junior Member

USA
113 Posts

Posted - 28 March 2006 :  09:51:51  Show Profile  Visit davidkirk's Homepage
How can I modify code or an existing admin setting (that I can't find) so that posts, except for sticky ones, will be sorted by popularity, i.e. posts with more readership appear first?

David Kirk

HuwR
Forum Admin

United Kingdom
20595 Posts

Posted - 28 March 2006 :  11:35:37  Show Profile  Visit HuwR's Homepage
you can't change the way they are sorted by default, but users have the ability to change the sort to how they want it using the topic sorting options at the bottom of the table on forum.asp
Go to Top of Page

muzishun
Senior Member

United States
1079 Posts

Posted - 28 March 2006 :  13:13:39  Show Profile  Visit muzishun's Homepage
There is a way to change the default view by editing the code. If you go into forum.asp, around lines 73-87, you'll find the following block:
Select Case strtopicsortfld
	Case "topic"
		strSortCol = "T_SUBJECT" & strSortOrd
	Case "author"
		strSortCol = "M_NAME" & strSortOrd
	Case "replies"
		strSortCol = "T_REPLIES" & strSortOrd
	Case "views"
		strSortCol = "T_VIEW_COUNT" & strSortOrd
	Case "lastpost"
		strSortCol = "T_LAST_POST" & strSortOrd
	Case Else
		strtopicsortfld = "lastpost"
		strSortCol = "T_LAST_POST" & strSortOrd
End Select

Change this to:
Select Case strtopicsortfld
	Case "topic"
		strSortCol = "T_SUBJECT" & strSortOrd
	Case "author"
		strSortCol = "M_NAME" & strSortOrd
	Case "replies"
		strSortCol = "T_REPLIES" & strSortOrd
	Case "views"
		strSortCol = "T_VIEW_COUNT" & strSortOrd
	Case "lastpost"
		strSortCol = "T_LAST_POST" & strSortOrd
	Case Else
		strtopicsortfld = "views"
		strSortCol = "T_VIEW_COUNT" & strSortOrd
End Select

This should change how topics are sorted. You can still order them manually by using HuwR's recommendation.

Bill Parrott
Senior Web Programmer, University of Kansas
Co-Owner and Code Monkey, Eternal Second Designs (www.eternalsecond.com)
Personal Website (www.chimericdream.com)
Go to Top of Page
  Previous Topic Topic Next Topic  
 New Topic  Topic Locked
 Printer Friendly
Jump To:
Snitz Forums 2000 © 2000-2021 Snitz™ Communications Go To Top Of Page
This page was generated in 1.9 seconds. Powered By: Snitz Forums 2000 Version 3.4.07