PDA

View Full Version : Request: Sort Users in the What's Going on Box by Last Activity.


neo1211
09-09-2009, 02:58 AM
Title says it all, I need a simple modification that will sort the users on the home page in the what's going on box by their last activity instead of by username or random. Anyone who can help me out would be much appreciated. I've dug around these forums for quite some time and found nothing that can do this, even though I know it should require nothing more than a small FORUMHOME edit.

Thanks in advance.

Lynne
09-09-2009, 03:47 AM
Have you tried just replacing the order part of the query in index.php?
" . iif($vbulletin->options['displayloggedin'] == 1 OR $vbulletin->options['displayloggedin'] == 3, "ORDER BY username ASC") . "

ORDER BY session.lastactivity

I haven't tried it, but that sounds like what you are asking for.

neo1211
09-09-2009, 04:30 AM
I haven't given that a try yet. I'm actually not the root admin on the forums I am trying to do this for, so I guess I'll have him give this a try once he logs on.

Edit- Worked perfectly. Recommended for anyone else trying to do this.

Thanks again.

Marco van Herwaarden
09-09-2009, 07:37 AM
Actually i think this can be done without any edits at all. If sorting is disabled (vBulletin Options!) it will probably show in the order the sessions where written, thus giving the same result.

(Without sorting is better for performance)