Advertisement
Abubakar1309

Untitled

Nov 15th, 2016
146
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.05 KB | None | 0 0
  1. <div class="author_block">
  2. <h2>About Author (<?php the_author_posts(); ?>)</h2>
  3. <div class="author_single">
  4. <table width="100%">
  5. <td class="avata_post"><?php echo get_avatar( get_the_author_meta('email'), '65' ); ?></td>
  6. <td class="author_name"><?php the_author_posts_link(); ?>
  7. <div class="user_role"><?php global $post;
  8. if ( user_can( $post->post_author, 'administrator' ) ) { ?>
  9. Administrator <img height="15px" width="15px" src="http://hamwap.com/img/verified-ceo.png" >
  10. <?php }
  11. elseif ( user_can( $post->post_author, 'editor' ) ) { ?>
  12. Editor <img src="editor image link" />
  13. <?php }
  14. elseif ( user_can( $post->post_author, 'author' ) ) {
  15. echo 'Author';
  16. }
  17. elseif ( user_can( $post->post_author, 'contributor' ) ) {
  18. echo 'Contributor';
  19. }
  20. elseif ( user_can( $post->post_author, 'subscriber' ) ) {
  21. echo 'Subscriber';}
  22. else {
  23. echo '<strong>Guest</strong>';
  24. }?></div>
  25. <p><?php the_author_meta('description'); if(!get_the_author_meta('description')) _e('This author may not interusted to share anything with others'); ?></p>
  26. </td>
  27. </table>
  28. </div></div>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement