Users
Infinite scroll WordPress authors with the Users add-on
The following shortcode was used to create the Users example.
[ajax_load_more users="true" users_role="Author" users_per_page="4" users_orderby="name" theme_repeater="users.php" transition="fade" seo="true" button_label="More Authors" button_loading_label="Loading Authors..."]
The following Repeater Template was used to create the Users example.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 |
<div class="author"> <?php echo get_avatar( $user->ID, 72 ); ?> <h3><?php echo $user->display_name; ?></h3> <p> <a href="<?php the_author_meta('user_url', $user->ID); ?>"> <?php the_author_meta('user_url', $user->ID); ?> </a> </p> <p><?php the_author_meta('description', $user->ID); ?></p> <?php if(get_the_author_meta('facebook', $user->ID) || get_the_author_meta('twitter', $user->ID)){ ?> <ul> <?php if(get_the_author_meta('facebook', $user->ID)){ ?> <li> <a href="<?php the_author_meta('facebook', $user->ID); ?>" class="facebook"><i class="fa fa-facebook"></i></a> </li> <?php } ?> <?php if(get_the_author_meta('twitter', $user->ID)){ ?> <li> <a href="<?php the_author_meta('twitter', $user->ID); ?>" class="twitter"><i class="fa fa-twitter"></i></a> </li> <?php } ?> </ul> <?php } ?> </div> |