Forums

Users table in admin: make role column sortable (2 posts)

  1. landwire
    Member
    Posted 7 months ago #

    Hi there,
    does anyone know how to make the "Role" column sortable? And while we are at it the "Posts" Column too?
    I appreciate a hint/solution very much!

  2. Tim S
    Member
    Posted 7 months ago #

    You'll need to use PHPmyAdmin to sort the column. So you'll need to write a query to do so. If you're writing it into the php code you can do something similar to this example in the link:

    http://wordpress.stackexchange.com/questions/11403/mysql-query-two-database-tables-users-and-usermeta-and-sort-by-custom-meta-int

    Basically, you'll need to use the SORT BY statement in your query.

Reply

You must log in to post.

About this Topic