WordPress.org

Ready to get started?Download WordPress

Forums

Post bulk nagivation problem (/page/2) (13 posts)

  1. filination
    Member
    Posted 8 years ago #

    Hi,

    In most WordPress blogs you can browse back to a previous bulk of posts by using the "/page/X" (X being a number) so that readers can browse pack to previous posts easily.
    If I understand correctly, and there's a good chance that I don't - then it refers to /index.php?paged=X (X being that same number).

    Now, both don't seem to work on my blog - http://www.filination.com/blog.
    As it shows up -exactly the same front page- when trying :
    http://www.filination.com/blog/index.php?paged=2
    or
    http://www.filination.com/blog/page/2

    Am I doing something wrong? is it the theme that I'm using? what should I do to add/fix this feature?

    Thanks in advance.

  2. filination
    Member
    Posted 7 years ago #

    Help?

  3. filination
    Member
    Posted 7 years ago #

    Help?

  4. Miner
    Member
    Posted 7 years ago #

    I am having the exact same problem for a couple of my clients. Did you ever get a response? I cannot find a solution to this.

    Thanks

  5. moshu
    Member
    Posted 7 years ago #

    Miner, what version of WP (since this is a half year old thread)?

  6. Miner
    Member
    Posted 7 years ago #

    Currently running Version 2.0.3

  7. moshu
    Member
    Posted 7 years ago #

    (In that branch the latest is 2.0.8 - always good to upgrade: security etc.)

    Did it ever work? Does it work if you switch to the default or classic theme?

  8. filination
    Member
    Posted 7 years ago #

    It was a bug in the theme I was using (Pressrow) that was defining the number of posts to show on the main page by code. I got rid of that, and walla - it was working.

  9. Miner
    Member
    Posted 7 years ago #

    It works with classic theme, but it does not have the blog rooted at /blog

    Site: http://skmurphy.com/blog/

    Page 2: http://skmurphy.com/blog/page/2/

    shows the same posts as page 1. It continues the paging until the end (clicking previous posts until on page 8), so I know the paging is working, but it is displaying only the first page of entries on every page.

  10. moshu
    Member
    Posted 7 years ago #

    I am confused by this:
    It works with classic theme, but it does not have the blog rooted at /blog

    Working measn it shows the right posts on page 2?

    What do you mean by "not rooted"?

  11. Miner
    Member
    Posted 7 years ago #

    Ok, well for this theme, we have the blog accessed through a page called /blog. this is because the site has many other pages and the blog is a subsection of the site.

    I think I found the offending code inside template blog.php (this is the template that the /blog page uses and it subsequently includes index.php), but I am not sure what to change it to.

    <?php
    /*
    Template Name: Blog
    */
    ?>

    <?php query_posts('cat=-0'); //gets all posts
    load_template( TEMPLATEPATH . '/index.php'); //loads index
    ?>

    ------------------------

    The line: query_posts('cat=-0');
    is causing the problem and defeating the paging code I think.

  12. moshu
    Member
    Posted 7 years ago #

    I stopped reading when saw this:
    Ok, well for this theme, we have the blog accessed through a page called /blog.
    With Pages it will not work.

  13. Miner
    Member
    Posted 7 years ago #

    Well thanks anyway, I guess...

    It appears that it DOES work under pages, just needed to pass on the paged variable on in the query mod. Changed one line:

    query_posts('cat=-0&paged='.$paged); //gets all posts and preserves paging

    So it works :)

Topic Closed

This topic has been closed to new replies.

About this Topic