-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy pathbiography.php
22 lines (21 loc) · 923 Bytes
/
biography.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
<?php
/**
* Add biography into single
* Using Co-authors plugin
* @copyright Copyright (C) 2020 Petr Kucera
* @license GPL(GPLv3)
*/
if(function_exists('coauthors_posts_links')){
global $post;
$author_id=$post->post_author;
foreach (get_coauthors() as $coauthor): ?>
<section class="post__footer__author">
<div class="post__footer__author__photo"><?php echo get_avatar( $coauthor->user_email, '96' ); ?></div>
<div class="post__footer__author__data">
<h2><a rel="author" class="post__footer__author__data__name" href="<?php echo get_author_posts_url($coauthor->ID, $coauthor->user_nicename); ?>"><?php echo $coauthor->display_name; ?></a></h2>
<p class="post__footer__author__data__description"><?php echo $coauthor->description; ?></p>
</div>
</section>
<?php endforeach;
}
?>