1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Order usernames chronologically

Discussion in 'XenForo Questions and Support' started by Luxus, Jun 5, 2012.

  1. Luxus

    Luxus Well-Known Member

    Hi,

    I think currently usernames in the sidebar are ordered by last activity, yes? Is it possible to order them chronologically (A first, Z last) by username?
     
  2. Syndol

    Syndol Guest

    You will have to edit some code in Model/Session.php
    In function getSessionActivityQuickList(), line 55
    change
    'order' => 'view_date'
    to
    'order' => 'username'
     
    Luxus likes this.
  3. Luxus

    Luxus Well-Known Member

    Wow, thank you very much. Too bad I have to edit a core file because this will be overwritten by an update.
    (CMS, Core Modification System, anyone? :p)
     
  4. Chris D

    Chris D XenForo Developer Staff Member

    Try this :)

    I've not tested it, but it's a proper add-on which implements Syndol's code change.
     

    Attached Files:

    Luxus likes this.
  5. Luxus

    Luxus Well-Known Member

    Hm.. I tried this add-on, but it doesn't seem to work.
     
  6. Chris D

    Chris D XenForo Developer Staff Member

    Works for me.

    Before:
    Before.PNG

    After:
    After.PNG

    Different users, but they're clearly alphabetical after the add-on is installed.

    You need to upload the contents of the upload folder to the root of your XF installation, then install in the Admin CP using the provided XML file.
     
  7. Luxus

    Luxus Well-Known Member

    That's strange, I did exactly that but usernames were still ordered by last activity. I can only try it with my own test accounts, though.
     
  8. ragtek

    ragtek Guest

    changes to $sessionModel->getSessionActivityQuickList affects more places and not only the online user sidebar on the index page!
    searchres.PNG

    You could try the attached version
     

    Attached Files:

  9. Luxus

    Luxus Well-Known Member

    Well, all that I can tell is that I applied the change in Syndol's post and it's working in the side bar only. According to your thumbnail it should also affect the recent activity and online page, but for me it didn't.
     
  10. Chris D

    Chris D XenForo Developer Staff Member

  11. Digital Doctor

    Digital Doctor Well-Known Member

    Order usernames chronologically

    would be a good idea for the memberlist !
     
  12. ragtek

    ragtek Guest

    strange

    thx for the reply:)
     

Share This Page