Question

Essentially what I'd like to do is have the same effect as the wp_list_authors tag, but instead of just listing the name or their post count, I want to be able to do a loop with the IDs. Ultimately I'd like have to a page with every author, with their name, description, avatar and link. I can figure out the specifics, I just need a way to do something like:

foreach $author as $author->ID

Thanks in advance,

Pete

Was it helpful?

Solution

Looks like you'll want to use get_users and you might want to take a look at the source code behind wp_list_authors to info on how to use it.

OTHER TIPS

You can also use WP_User_Query to loop through users. You can pull user meta data (anything stored in the user profile) through this class - and you can also limit by user role/level (IE, run a different query for admins, editors, subscribers, etc.)

Licensed under: CC-BY-SA with attribution
Not affiliated with wordpress.stackexchange
scroll top