Results 1 to 2 of 2

Thread: Post Navigation Help

  1. #1
    Guest

    Default Post Navigation Help

    Hi, my theme is not displaying a 'previous post' or 'next post' link
    I believe the code for it (although slightly different) is in the single post loop already

    <?php the_content( __('<p>Read the rest of this entry &raquo;</p>', 'arras') ); ?>
    <?php wp_link_pages(array('before' => __('<p><strong>Pages:</strong> ', 'arras'),
    'after' => '</p>', 'next_or_number' => 'number'));

    I may be wrong of course, but even if i do enter the code <?php previous_posts_link(); ?>
    <?php next_posts_link(); ?>
    into the loop or even in individual post's i get nothing. It seems my theme just ignores the code, as if i have a setting wrong somewhere?
    Any help much appreciated

  2. #2
    saitfainder's Avatar
    saitfainder is offline AlterVista Staff
    Join Date
    Feb 2010
    Posts
    300

    Default

    I don't know what you are going do to but:

    wp_link_pages() should be used only for paginated posts (posts with <!--nextpage--> quicktag)

    previous_posts_link() and next_posts_link() are relative to a query, so they have to be placed outside the loop.
    "Over thinking, over analyzing separates the body from the mind."

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  

SEO by vBSEO