Avoid going in and out of PHP unnecessarily.
Closes #854 Includes minor alignment changes for easier readability/detection of start/end of conditions.
This commit is contained in:
parent
6f6de25568
commit
8470f55f92
13 changed files with 128 additions and 109 deletions
25
single.php
25
single.php
|
@ -12,23 +12,24 @@ get_header(); ?>
|
|||
<div id="primary" class="content-area">
|
||||
<main id="main" class="site-main" role="main">
|
||||
|
||||
<?php while ( have_posts() ) : the_post(); ?>
|
||||
<?php
|
||||
while ( have_posts() ) : the_post();
|
||||
|
||||
<?php get_template_part( 'template-parts/content', 'single' ); ?>
|
||||
get_template_part( 'template-parts/content', 'single' );
|
||||
|
||||
<?php the_post_navigation(); ?>
|
||||
the_post_navigation();
|
||||
|
||||
<?php
|
||||
// If comments are open or we have at least one comment, load up the comment template.
|
||||
if ( comments_open() || get_comments_number() ) :
|
||||
comments_template();
|
||||
endif;
|
||||
?>
|
||||
// If comments are open or we have at least one comment, load up the comment template.
|
||||
if ( comments_open() || get_comments_number() ) :
|
||||
comments_template();
|
||||
endif;
|
||||
|
||||
<?php endwhile; // End of the loop. ?>
|
||||
endwhile; // End of the loop.
|
||||
?>
|
||||
|
||||
</main><!-- #main -->
|
||||
</div><!-- #primary -->
|
||||
|
||||
<?php get_sidebar(); ?>
|
||||
<?php get_footer(); ?>
|
||||
<?php
|
||||
get_sidebar();
|
||||
get_footer();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue