Author |
Topic  |
|
GarethMoore1979
Junior Member
 
United Kingdom
220 Posts |
Posted - 29 June 2004 : 16:27:23
|
The current default view in members.asp is to display them by their post count.
What I want is to display by their status. So Admin at the top, then moderators (in order of post count) and then members (in order of post count).
Now I have been looking at this code here:
quote: select case SortMethod case "nameasc" strSql4 = " ORDER BY M_NAME ASC" case "namedesc" strSql4 = " ORDER BY M_NAME DESC" case "levelasc" strSql4 = " ORDER BY M_TITLE ASC, M_NAME ASC" case "leveldesc" strSql4 = " ORDER BY M_TITLE DESC, M_NAME ASC" case "lastpostdateasc" strSql4 = " ORDER BY M_LASTPOSTDATE ASC, M_NAME ASC" case "lastpostdatedesc" strSql4 = " ORDER BY M_LASTPOSTDATE DESC, M_NAME ASC" case "lastheredateasc" strSql4 = " ORDER BY M_LASTHEREDATE ASC, M_NAME ASC" case "lastheredatedesc" strSql4 = " ORDER BY M_LASTHEREDATE DESC, M_NAME ASC" case "dateasc" strSql4 = " ORDER BY M_DATE ASC, M_NAME ASC" case "datedesc" strSql4 = " ORDER BY M_DATE DESC, M_NAME ASC" case "countryasc" strSql4 = " ORDER BY M_COUNTRY ASC, M_NAME ASC" case "countrydesc" strSql4 = " ORDER BY M_COUNTRY DESC, M_NAME ASC" case "postsasc" strSql4 = " ORDER BY M_POSTS ASC, M_NAME ASC" case else strSql4 = " ORDER BY M_STATUS, M_POSTS DESC" end select
I have tried to alter this bit in red at the bottom. I have added the M_STATUS bit. But it just doesnt work. Has anyone done this before? |
|
RichardKinser
Snitz Forums Admin
    
USA
16655 Posts |
Posted - 29 June 2004 : 16:39:23
|
M_STATUS is used to show the status of a member 1 = active, 0 = locked, etc..
Try using M_LEVEL, and you'll need to sort it descending, because 1=Normal, 2=Moderator, 3=Admin |
 |
|
GarethMoore1979
Junior Member
 
United Kingdom
220 Posts |
Posted - 29 June 2004 : 19:13:37
|
doh! I knew that it was M_LEVEL 
anyway, that worked!! thanks!!
it now looks like this: quote: case else strSql4 = " ORDER BY M_LEVEL DESC, M_POSTS DESC"
|
 |
|
|
Topic  |
|
|
|