I'm trying to build an author list that would show all authors that have written a Custom Post Type post, and hide authors that have no posts. With wp_list_authors it would be easy to show users that have written Posts (not CPT).
This does not show the users that have published Custom Post Types, it affects only to Posts.
wp_list_authors('hide_empty=1');
I looked in to the get_users function but managed to only build a list with it (more control over the list but not what I was aiming for).
$blog_url = get_bloginfo('home');
$blogusers = get_users('orderby=display_name&role=editor');
foreach ($blogusers as $user) {
echo '<li><a href="' . $blog_url . '/author/' . $user->user_login . '">' . $user->display_name . '</a></li>';
}
I found this really nice post dealing with how to show the post counts in the backend. It defines a function _yoursite_get_author_post_type_counts() that could possibly maybe be some help in this...
Any idea how to do this? Thanks! :)