index.php 2.8 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677
  1. <?php get_header(); ?>
  2. <div id="content" class="clearfix">
  3. <div id="main" class="col620 left first clearfix" role="main">
  4. <?php if (have_posts()) : while (have_posts()) : the_post(); ?>
  5. <article id="post-<?php the_ID(); ?>" <?php post_class('clearfix'); ?> role="article">
  6. <header>
  7. <h1 class="h2"><a href="<?php the_permalink() ?>" rel="bookmark" title="<?php the_title_attribute(); ?>"><?php the_title(); ?></a></h1>
  8. <p class="meta"><?php _e('Posted', 'bonestheme'); ?> <time datetime="<?php echo the_time('Y-m-j'); ?>" pubdate><?php the_time(get_option('date_format')); ?></time> <?php _e('by', 'bonestheme'); ?> <?php the_author_posts_link(); ?> <span class="amp">&</span> <?php _e('filed under', 'bonestheme'); ?> <?php the_category(', '); ?>.</p>
  9. </header> <!-- end article header -->
  10. <section class="post_content clearfix">
  11. <?php
  12. $more_link_text = '<span class="read-more">' . __('Read more on', 'bonestheme') . the_title(' "', '" &raquo;</span>', false) ;
  13. the_content( $more_link_text );
  14. ?>
  15. </section> <!-- end article section -->
  16. <footer>
  17. <?php // count tags of post and use plural where appropriate
  18. $posttags = get_the_tags(); $count=0; if ($posttags) { foreach($posttags as $tag) { $count++; } };
  19. $before_tags_text = '<p class="tags"><span class="tags-title">' . _n('Tag', 'Tags', $count, 'bonestheme') . '</span>: ';
  20. the_tags( $before_tags_text, ', ', '</p>');
  21. ?>
  22. </footer> <!-- end article footer -->
  23. </article> <!-- end article -->
  24. <?php comments_template(); ?>
  25. <?php endwhile; ?>
  26. <?php if (function_exists('page_navi')) { // if experimental feature is active ?>
  27. <?php page_navi(); // use the page navi function ?>
  28. <?php } else { // if it is disabled, display regular wp prev & next links ?>
  29. <nav class="wp-prev-next">
  30. <ul class="clearfix">
  31. <li class="prev-link"><?php next_posts_link(_e('&laquo; Older Entries', 'bonestheme')) ?></li>
  32. <li class="next-link"><?php previous_posts_link(_e('Newer Entries &raquo;', 'bonestheme')) ?></li>
  33. </ul>
  34. </nav>
  35. <?php } ?>
  36. <?php else : ?>
  37. <article id="post-not-found">
  38. <header>
  39. <h1><?php _e('Not Found', 'bonestheme') ?></h1>
  40. </header>
  41. <section class="post_content">
  42. <p><?php _e('Sorry, but the requested resource was not found on this site.', 'bonestheme'); ?></p>
  43. </section>
  44. <footer>
  45. </footer>
  46. </article>
  47. <?php endif; ?>
  48. </div> <!-- end #main -->
  49. <?php get_sidebar(); // sidebar 1 ?>
  50. </div> <!-- end #content -->
  51. <?php get_footer(); ?>