Forums

Next + Previous Post links (4 posts)

  1. hlei
    Member
    Posted 2 years ago #

    So I finally got the next_pages tag working, though I don't know for the life of me how. But I cannot figure out how to get the Next Post / Previous Post tags to work.

    I have this code:

    <?php next_post_link('format', 'link', in_same_cat, 'excluded_categories'); ?>
    <?php previous_post_link('format', 'link', in_same_cat, 'excluded_categories'); ?>

    in my index.php file and my archive.php file.

    I have this code:
    <?php next_post_link('&laquo; Previous &laquo;') ?> &#8734 <?php previous_post_link('&raquo; Next &raquo;') ?>
    on my single.php page.

    I've read everything I can get my hands on, but have yet to find out exactly where I'm supposed to put the first code, and exactly where I'm supposed to put the second code.

    Everything is up on my site, springmilk.com.

  2. Rhand
    Member
    Posted 2 years ago #

    I use

    <?php next_posts_link('&laquo; Previous Posts') ?>
    <?php previous_posts_link('Next Posts &raquo;') ?>

    on most index.php pages for the blog page and it works just fine.

  3. hlei
    Member
    Posted 2 years ago #

    It doesn't work.
    I put it inside the Loop, and it does nothing. : \

  4. Rhand
    Member
    Posted 2 years ago #

    Maybe you should post your code for the page where you added the code snippet. I will have a look as a soon as I can. And as you post this other forum members can help out as well. By the way, did you get any Apache errors? These might us find the culprit?

Topic Closed

This topic has been closed to new replies.

About this Topic