如果您需要定制的解决方案,那么您可以像这样使用用户查询。
<?php
$args = array(
\'who\' => \'authors\',
\'orderby\' => \'display_name\'
);
$wp_user_query = new WP_User_Query($args);
if ( ! empty( $wp_user_query->results ) ) {
foreach ( $wp_user_query->results as $user ) {
echo \'<span class="abc"><a href="\' . get_author_posts_url( $user->ID ) . \'">\' . $user->display_name . \'</a></span>\';
}
}
?>