Forums

The forums ran from 2008-2020 and are now closed and viewable here as an archive.

Home Forums Back End problem with nav on wp theme

  • This topic is empty.
Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
    Posts
  • #31064

    Hi
    I have problems with navigation on my wordpress theme.
    I have made a page template that includes posts for one category. I used a .
    If I limit the number of posts per page to 5 (example) in my admin panel and if I put a , it does not work… It always put the same 5 last posts when I click on the link “next page”…

    The code:

    
    /*
    Template Name: blog photo
    */

    ?>













    ">










    'Pages: ', 'next_or_number' => 'number')); ?>



    ', '

    '); ?>











    Can anyone tell my were the problem is?
    Thank you
    Hubert

    #69292

    By the way: my web site is http://www.hubertvincent-blog.com

    #69293
    clokey2k
    Participant

    query_post(); – will reset the query from the page URL.

    You ask for page 2 in the URL, and query_post() ignores it!

    Watch this: https://css-tricks.com/video-screencasts/91-the-wordpress-loop/

    Chris shows you how to use an offset later in the video, or how to preserve the original query. Either one will help you.

Viewing 3 posts - 1 through 3 (of 3 total)
  • The forum ‘Back End’ is closed to new topics and replies.