• First of all, I’m really sorry if there’s already a topic about this same problem. I just couldn’t find one.

    The problem:

    I’m having a frontpage which consists of two columns. First one shows three latest posts from a category called “yleinen” and the second one shows three latest posts from “kritiikki”. Well everything works fine besides that previous_posts_link doesn’t work.

    Url changes to /page/2/ but nothing happens to the actual posts.

    Here’s my code from index.php

    <?php
    get_header(); ?>
    
    	<div id="content" role="main">
    
                <div class="left">
    <?php query_posts('category_name=yleinen&posts_per_page=3'); ?>
    <?php if (have_posts()) : ?>
    		<?php while (have_posts()) : the_post(); ?>
    <div class="box-left">
    <div class="aika"><?php the_time('d.m.Y') ?></div>
    <div class="title"><?php the_title(); ?></div>
    <?php the_content('more ?'); ?></div>
    <?php endwhile; ?>
    			</div>
    
                            <div class="right">
    <?php query_posts('category_name=kritiikki&posts_per_page=3'); ?>
    		<?php while (have_posts()) : the_post(); ?>
    <div class="box-right">
    <div class="aika"><?php the_time('d.m.Y') ?></div>
    <div class="title"><?php the_title(); ?></div>
    <div class="floatright"><?php the_post_thumbnail(); ?></div>
    <?php the_excerpt(); ?>
    </div>
    
    <?php endwhile; ?>
    
        <div class="navigation">
    			<?php next_posts_link(__('? Older Entries')) ?>
    			<?php previous_posts_link(__('Newer Entries ?')) ?>
    		</div>
    
    <?php endif; ?>
    			</div>
    
    	</div>
    
    <?php get_footer(); ?>
Viewing 1 replies (of 1 total)
Viewing 1 replies (of 1 total)
  • The topic ‘previous_posts_link and index.php Problem’ is closed to new replies.