I am having a problem with my blog page archive.php. When I click the next link at the bottom navigation there are no more posts.
I have a pretty basic setup which works fine for my search.php, the only real difference being the featured section, what am I doing wrong?
archive.php:
<?php get_header(); ?>
<div id="content">
<div class="content-inner">
<div class="content-two content-blog">
<div class="content-cell">
<h3 class="blog-heading">Blog</h3>
<?php if ( have_posts() ) : while ( have_posts() ) : the_post();?>
<div class="entry">
<h3 class="entry-title"><a href="<?php the_permalink() ?>" rel="bookmark" title="Permanent Link to <?php the_title_attribute(); ?>"><?php the_title(); ?></a></h3>
<div class="entry-details">
<span class="entry-author"><?php the_author_link(); ?></span>
<span class="entry-date"><?php the_time('M j, Y') ?></span>
</div>
<hr/>
<div class="entry-content">
<?php the_content(); ?>
</div>
</div>
<?php endwhile; ?>
<?php
$prev_link = get_previous_posts_link(__('<span class="page-prev"><i class="material-icons"></i>Prev</span>'));
$next_link = get_next_posts_link(__('<span class="page-next">Next<i class="material-icons"></i></span>'));
if ($prev_link || $next_link) : ?>
<div class="navigation"><p>
<?php
if ($prev_link){
echo $prev_link;
} else {
echo '<span class="page-prev"><i class="material-icons"></i>Prev</span>';
}
echo ' - ';
if ($next_link){
echo $next_link;
} else {
echo '<span class="page-next">Next<i class="material-icons"></i></span>';
}
?>
</p></div>
<?php endif; ?>
<?php endif; ?>
</div>
<div class="content-cell featured-cell">
<h3 class="featured-heading">Featured Posts</h3>
<?php query_posts( array(
'post_type' => 'post',
'posts_per_page' => -1 )
);
?>
<?php if ( have_posts() ) while ( have_posts() ) : the_post(); ?>
<?php if ( has_post_thumbnail() ) : ?>
<div class="feature">
<a href="<?php the_permalink() ?>" rel="bookmark" title="Permanent Link to <?php the_title_attribute(); ?>">
<?php the_post_thumbnail('thumbnail'); ?>
<span class="featured-title"><?php the_title(); ?></span>
</a>
</div>
<?php endif; ?>
<?php endwhile; ?>
<?php wp_reset_query(); ?>
</div>
</div><!-- End of .content-two-->
</div><!-- End of .content-inner-->
</div><!-- End of #content-->
<?php get_footer(); ?>