archive-custom_type.php 2.3 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273
  1. <?php get_header(); ?>
  2. <div id="content">
  3. <div id="inner-content" class="wrap clearfix">
  4. <div id="main" class="eightcol first clearfix" role="main">
  5. <h1 class="archive-title h2"><?php post_type_archive_title(); ?></h1>
  6. <?php if (have_posts()) : while (have_posts()) : the_post(); ?>
  7. <article id="post-<?php the_ID(); ?>" <?php post_class( 'clearfix' ); ?> role="article">
  8. <header class="article-header">
  9. <h3 class="h2"><a href="<?php the_permalink() ?>" rel="bookmark" title="<?php the_title_attribute(); ?>"><?php the_title(); ?></a></h3>
  10. <p class="byline vcard"><?php
  11. printf( __( 'Posted <time class="updated" datetime="%1$s" pubdate>%2$s</time> by <span class="author">%3$s</span>.', 'bonestheme' ), get_the_time( 'Y-m-j' ), get_the_time( __( 'F jS, Y', 'bonestheme' ) ), bones_get_the_author_posts_link());
  12. ?></p>
  13. </header>
  14. <section class="entry-content clearfix">
  15. <?php the_excerpt(); ?>
  16. </section>
  17. <footer class="article-footer">
  18. </footer>
  19. </article>
  20. <?php endwhile; ?>
  21. <?php if ( function_exists( 'bones_page_navi' ) ) { ?>
  22. <?php bones_page_navi(); ?>
  23. <?php } else { ?>
  24. <nav class="wp-prev-next">
  25. <ul class="clearfix">
  26. <li class="prev-link"><?php next_posts_link( __( '&laquo; Older Entries', 'bonestheme' )) ?></li>
  27. <li class="next-link"><?php previous_posts_link( __( 'Newer Entries &raquo;', 'bonestheme' )) ?></li>
  28. </ul>
  29. </nav>
  30. <?php } ?>
  31. <?php else : ?>
  32. <article id="post-not-found" class="hentry clearfix">
  33. <header class="article-header">
  34. <h1><?php _e( 'Oops, Post Not Found!', 'bonestheme' ); ?></h1>
  35. </header>
  36. <section class="entry-content">
  37. <p><?php _e( 'Uh Oh. Something is missing. Try double checking things.', 'bonestheme' ); ?></p>
  38. </section>
  39. <footer class="article-footer">
  40. <p><?php _e( 'This is the error message in the custom posty type archive template.', 'bonestheme' ); ?></p>
  41. </footer>
  42. </article>
  43. <?php endif; ?>
  44. </div>
  45. <?php get_sidebar(); ?>
  46. </div>
  47. </div>
  48. <?php get_footer(); ?>