author.php 2.9 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182
  1. <?php get_header(); ?>
  2. <div id="content" class="clearfix">
  3. <div id="main" class="col620 left first clearfix" role="main">
  4. <h1 class="archive_title h2">
  5. <span><?php _e("Posts By:", "bonestheme"); ?></span>
  6. <!-- google+ rel=me function -->
  7. <?php $curauth = (get_query_var('author_name')) ? get_user_by('slug', get_query_var('author_name')) : get_userdata(get_query_var('author'));
  8. $google_profile = get_the_author_meta( 'google_profile', $curauth->ID );
  9. if ( $google_profile ) {
  10. echo '<a href="' . esc_url( $google_profile ) . '" rel="me">' . $curauth->display_name . '</a>'; ?>
  11. <?php } else { ?>
  12. <?php echo get_author_name(get_query_var('author')); ?>
  13. <?php } ?>
  14. </h1>
  15. <?php if (have_posts()) : while (have_posts()) : the_post(); ?>
  16. <article id="post-<?php the_ID(); ?>" <?php post_class('clearfix'); ?> role="article">
  17. <header>
  18. <h3 class="h2"><a href="<?php the_permalink() ?>" rel="bookmark" title="<?php the_title_attribute(); ?>"><?php the_title(); ?></a></h3>
  19. <p class="meta"><?php _e("Posted", "bonestheme"); ?> <time datetime="<?php echo the_time('Y-m-j'); ?>" pubdate><?php the_time('F jS, Y'); ?></time> <?php _e("by", "bonestheme"); ?> <?php the_author_posts_link(); ?> <span class="amp">&</span> <?php _e("filed under", "bonestheme"); ?> <?php the_category(', '); ?>.</p>
  20. </header> <!-- end article header -->
  21. <section class="post_content">
  22. <?php the_post_thumbnail( 'bones-thumb-300' ); ?>
  23. <?php the_excerpt(); ?>
  24. </section> <!-- end article section -->
  25. <footer>
  26. </footer> <!-- end article footer -->
  27. </article> <!-- end article -->
  28. <?php endwhile; ?>
  29. <?php if (function_exists('page_navi')) { // if expirimental feature is active ?>
  30. <?php page_navi(); // use the page navi function ?>
  31. <?php } else { // if it is disabled, display regular wp prev & next links ?>
  32. <nav class="wp-prev-next">
  33. <ul class="clearfix">
  34. <li class="prev-link"><?php next_posts_link(_e('&laquo; Older Entries', "bonestheme")) ?></li>
  35. <li class="next-link"><?php previous_posts_link(_e('Newer Entries &raquo;', "bonestheme")) ?></li>
  36. </ul>
  37. </nav>
  38. <?php } ?>
  39. <?php else : ?>
  40. <article id="post-not-found">
  41. <header>
  42. <h1><?php _e("No Posts Yet", "bonestheme"); ?></h1>
  43. </header>
  44. <section class="post_content">
  45. <p><?php _e("Sorry, What you were looking for is not here.", "bonestheme"); ?></p>
  46. </section>
  47. <footer>
  48. </footer>
  49. </article>
  50. <?php endif; ?>
  51. </div> <!-- end #main -->
  52. <?php get_sidebar(); // sidebar 1 ?>
  53. </div> <!-- end #content -->
  54. <?php get_footer(); ?>