WordPress.org

Ready to get started?Download WordPress

Forums

[resolved] next_posts_link not working on single.php (2 posts)

  1. yankeyhotel
    Member
    Posted 4 years ago #

    I am using a pretty simple single.php page and I am having a hard time getting the next_posts_link and previous_post_link to work correctly. I am using the basic single.php structure.

    <?php if (have_posts()) : while (have_posts()) : the_post(); ?>
    <?php endwhile; else: ?>
    <?php endif; ?>
    <p class="small"><?php next_posts_link(); ?></p>
    <p class="small"><?php previous_posts_link(); ?></p>

    I have tried putting it inside the loop outside the loop, but nothing will get it to show up? Any ideas. thank you in advance.

  2. yankeyhotel
    Member
    Posted 4 years ago #

    never mind I am an idiot, this always happens when I post a question.

    next_post_link() & previous_post_link()

Topic Closed

This topic has been closed to new replies.

About this Topic