single.php 671 B

12345678910111213141516171819202122232425262728
  1. <?php
  2. /**
  3. * The template for displaying all single posts.
  4. *
  5. * @link https://developer.wordpress.org/themes/basics/template-hierarchy/#single-post
  6. *
  7. * @package Pen
  8. */
  9. get_header(); ?>
  10. <div id="primary" class="content-area">
  11. <main id="main" class="<?php echo esc_attr( pen_content_classes() ); ?>" role="main">
  12. <div class="pen_article_wrapper">
  13. <?php
  14. while ( have_posts() ) {
  15. the_post();
  16. get_template_part( 'partials/content', get_post_type() );
  17. // If comments are open or we have at least one comment, load up the comment template.
  18. if ( comments_open() || get_comments_number() ) {
  19. comments_template();
  20. }
  21. }
  22. ?>
  23. </div>
  24. </main>
  25. </div>
  26. <?php
  27. get_footer();