Initiate the loop before the title is called on pages. Failing to do so causes checks that run on the loop's status to fail.

This commit is contained in:
Josh Levinson
2014-06-13 14:09:20 -04:00
parent dbb80938e0
commit 2d1c77837b
2 changed files with 6 additions and 6 deletions

View File

@@ -1,2 +1,4 @@
<?php get_template_part('templates/page', 'header'); ?>
<?php get_template_part('templates/content', 'page'); ?>
<?php while (have_posts()) : the_post(); ?>
<?php get_template_part('templates/page', 'header'); ?>
<?php get_template_part('templates/content', 'page'); ?>
<?php endwhile; ?>

View File

@@ -1,4 +1,2 @@
<?php while (have_posts()) : the_post(); ?>
<?php the_content(); ?>
<?php wp_link_pages(array('before' => '<nav class="pagination">', 'after' => '</nav>')); ?>
<?php endwhile; ?>
<?php the_content(); ?>
<?php wp_link_pages(array('before' => '<nav class="pagination">', 'after' => '</nav>')); ?>