All Questions
11 questions
0
votes
1
answer
258
views
Sorting Users page admin column with ACF field
I have a CPT called Companies. I created an ACF relationship field called user_company that gets displayed in the Users profile page.
When a user registers, I have to go in and assign them to a ...
0
votes
0
answers
44
views
meta_query orderby sort multiple keys
I'm trying to read the birthdays of the users in my database through custom fields that have been added. Displaying the current months is easy but I am trying to capture the current month(remainder) ...
1
vote
0
answers
71
views
Column Sorting Code on users.php
I have added some custom code to my functions.php to add column sorting for several of my custom meta fields. I have encountering two issues. 1. For some reason when I add this code all of the data ...
0
votes
2
answers
12k
views
How can I sort get_users() by any value (last_name, user defined fields and more)
I want to sort the result of get_users() by last name, first name, user defined fields or whatever.
How can I achieve this while still using get_users()?
3
votes
2
answers
894
views
What is the most efficient way to search users by their display name?
Initially I thought I'd use get_users() but it turned out it doesn't support the display_name field. Then I've read about using WP_User_Query, but when I do it always exhausts the allowed memory size ...
0
votes
1
answer
205
views
How to order posts by the user_login that corresponds to a meta_value (which is a user id)?
I'm trying to create sortable column headers for a CPT list, but I'm stuck on one piece. When clicking on an "Assignee" column head, I want the list to display alphabetically by the login name of the ...
0
votes
1
answer
876
views
wp-admin: Sort users by surname
Is it possible to alter this table in the backend so I can sort users by Name and Surname?
I have dozens of users on my multisite that need to be sorted by Surname.
Can anyone help me out here?
Kind ...
4
votes
3
answers
10k
views
How to order users alphabetically by their last name?
I use the following shortcode and function to display members of some departments:
add_shortcode( 'list_of_members', 'members_listing' );
/* usage: [list_of_members department = 'psychology'] */
...
3
votes
3
answers
2k
views
Sort users in get_users() in custom order
<?php
$blogusers = get_users('include=5,6,2,7,12,8');
foreach ($blogusers as $user) {
...
}
?>
Right now, these users will sorted by first name.
How do I sort this in the order the ...
1
vote
1
answer
2k
views
How to use WP default post list tables in a plugin?
I'm developping a plugin to manage a base of users and I'd like to show them in the same type of table used in other parts of the WP admin (post lists, user lists, etc.), I'd like to have the same ...
0
votes
1
answer
2k
views
How to let users choose posts order in categories?
I'm running a wordpress based website and I need to let the users choose how to show the posts inside categories pages.
I would like to have a button inside a category page that can be clicked so the ...