Sorting of top users

Register an Account
Reply
 
Thread Tools Display Modes
  #1 (permalink)  
Old 07-06-2007, 08:10 PM
Constant Pligger
 
Join Date: Apr 2007
Posts: 1,042
How can I sort the top users by the number of their submitted stories in descending order?
Reply With Quote
  #2 (permalink)  
Old 07-06-2007, 08:30 PM
chuckroast's Avatar
Pligg Developer/Coder/Designer
Pligg Version: SVN
Pligg Template: Social Pro Kit
 
Join Date: Jun 2006
Posts: 5,448
Change the link top users so it points to topusers.php?sortby=1 instead of topusers.php

You can make the change in your header.tpl file
Reply With Quote
  #3 (permalink)  
Old 07-07-2007, 02:38 AM
Constant Pligger
 
Join Date: Apr 2007
Posts: 1,042
Version 9.5 actually uses $URL_topusers that I´ve substituted with $my_base_url/topusers.php?sortby=1 --> doesn´t work

I´ve tried the full path but then the path is crippled to domain.com/topusers.phpsortby

Code:
<a href='http://www.domain.com/topusers.php?sortby=1'> {#PLIGG_Visual_Top_Users#}</a> &nbsp;&nbsp;
Reply With Quote
  #4 (permalink)  
Old 07-08-2007, 04:19 PM
Pligg Donor
 
Join Date: Mar 2007
Posts: 85
Quote:
Originally Posted by tbones View Post
Version 9.5 actually uses $URL_topusers that I´ve substituted with $my_base_url/topusers.php?sortby=1 --> doesn´t work

I´ve tried the full path but then the path is crippled to domain.com/topusers.phpsortby

Code:
<a href='http://www.domain.com/topusers.php?sortby=1'> {#PLIGG_Visual_Top_Users#}</a> &nbsp;&nbsp;
This is working for me (though I'm using 9.6 - but I don't think this file changed) -
Code:
<a href="{$my_base_url}{$my_pligg_base}/topusers.php?sortby=6">
Have you tried using double quotes instead of single quotes? (fyi - '6' is sorting it by karma for me)
Reply With Quote
  #5 (permalink)  
Old 07-08-2007, 05:56 PM
Constant Pligger
 
Join Date: Apr 2007
Posts: 1,042
Quote:
Originally Posted by betagirl View Post
Code:
<a href="{$my_base_url}{$my_pligg_base}/topusers.php?sortby=6">
Have you tried using double quotes instead of single quotes? (fyi - '6' is sorting it by karma for me)
It works also with v9.5 and sortby=1, thank you.

But - all the users without a submission don´t show up anymore. Take the example of someone who already wrote an comment but hasn´t submitted anything so far. He/she isn´t on the initial list but will show up if you click on the comments column. That´s a bug.

Edit: I guess a conditional "where comments>0 or submitted>0" could solve the problem

Last edited by tbones; 07-09-2007 at 05:11 AM. Reason: Solution suggestion
Reply With Quote
  #6 (permalink)  
Old 07-08-2007, 07:12 PM
P1mpPanther's Avatar
Constant Pligger
 
Join Date: Feb 2007
Posts: 277
@tbones - thanks for confirming that bug. Was noticing some odd behavior when sorting
Reply With Quote
  #7 (permalink)  
Old 07-09-2007, 04:56 AM
Constant Pligger
 
Join Date: Apr 2007
Posts: 1,042
I´ve noticed that users with the same amount of comments/posts etc. are sorted in a random order. What has to be changed to order those alphabetically?
Reply With Quote
  #8 (permalink)  
Old 09-17-2007, 05:10 PM
helmeloh's Avatar
New Pligger
Pligg Version: 9.9
Pligg Template: yget
 
Join Date: Jul 2007
Location: Vienna, Austria
Posts: 10
Thank you, that was helpful for me, now I got ordered Top users (;-)
Reply With Quote
  #9 (permalink)  
Old 02-06-2008, 06:32 PM
Constant Pligger
 
Join Date: Apr 2007
Posts: 1,042
So I assume this problem has gone with the newer versions. :-)
Reply With Quote
  #10 (permalink)  
Old 02-07-2008, 02:41 PM
New Pligger
Pligg Version: 9.9.0
Pligg Template: yget
 
Join Date: Jan 2008
Posts: 2
Quote:
Originally Posted by tbones View Post
So I assume this problem has gone with the newer versions. :-)
No, the problem remains, but it looks more like a misunderstanding created by the language file. Instead of "Top Users" could be used "Registered users" or "All users"

Pligg 9.9.0 (yget template) has
PHP Code:
<a href='{$URL_topusers}'> {#PLIGG_Visual_Top_Users#}</a> &nbsp;&nbsp; 
line 47.
Reply With Quote
Reply

Thread Tools
Display Modes


Similar Threads
Thread Thread Starter Forum Replies Last Post
Delete users from database and admin user management bbrian017 Questions and Comments 18 02-22-2011 12:51 AM
No users on YGET Manage Users page JAPUNDIT Questions and Comments 2 08-02-2008 02:09 AM
How to sort top users by category in 'Top Users' page aaronpais Questions and Comments 0 05-16-2007 09:55 AM
Top users sorting not working correctly. Nikes77 Questions and Comments 0 12-07-2006 07:46 AM
Total votes sorting in top users page it is not working correctly! Nikes77 Questions and Comments 2 12-06-2006 07:10 PM


Pligg Modules and Pligg Templates from Pligg Pro Find support on the Pligg CMS Forum - 24 hours a day! Make a donation to support Pligg CMS development