WordPress.org

Ready to get started?Download WordPress

Forums

Previous Posts Problems (11 posts)

  1. Graphicary
    Member
    Posted 7 years ago #

    I'm having some problems with my "previous posts" link at the bottom of my blog. I've used the search function but didn't find exactly what I was looking for.

    Anyway, the problem is that when I click on the "previous posts" link it wants to take me to http://www.mydomain.com/blog/blog/page2, rather than the correct page which is http://www.mydomain.com/blog/page/2. I can't for the life of me figure out how to get it to not double the "/blog" part of the url. If I manually type in http://www.mydomain.com/blog/page/2 it works fine and the page displays as it should. Even the "next post" link works correctly and takes me to http://www.mydomain.com/blog.

    The php for the link looks like this:

    <p><span class="next"><?php previous_posts_link('Next Posts') ?></span>
    <span class="previous"><?php next_posts_link('Previous Entries') ?></span></p>

    And the .htaccess file looks like:

    <IfModule mod_rewrite.c>
    RewriteEngine On
    RewriteBase /wordpress/
    RewriteCond %{REQUEST_FILENAME} !-f
    RewriteCond %{REQUEST_FILENAME} !-d
    RewriteRule . /wordpress/index.php [L]
    </IfModule>

    No idea if it has anything to do with either of those, as I'm not a coder, but from what I saw in my search of the forum those two pieces of code came up often so I thought I'd post them.

    Any help? There's got to be some way to fix this but I can't see how. I'm no coder so it's possible that it's something simple and I just don't see it.

  2. moshu
    Member
    Posted 7 years ago #

    That's an old tag - use the latest one:
    http://codex.wordpress.org/Template_Tags/posts_nav_link

  3. Graphicary
    Member
    Posted 7 years ago #

    Thanks moshu. I thought I'd read somewhere that the tag was outdated. Glad you pointed me to the right one. Unfortunately, other than making the code a little easier to read, it didn't do anything to fix the problem. The link still wants to take me to /blog/blog/page/2 rather than /blog/page/2.

    This is driving me nuts!

  4. Graphicary
    Member
    Posted 7 years ago #

    Just a quick bump since I posted it at a rather odd hour and likely not a lot of people saw it.

    Anyone have any ideas or suggestions? They'd be greatly appreciated.

  5. toddorado
    Member
    Posted 6 years ago #

    I am having the same problem when, after transferring all of my WP 2.3 files over and going to the upgrade page, the end result is a blog/blog scenario in the URL. I've never had this problem in previous upgrades. Thought it might be in one of the index.php files, but that seemed to be a dead end. Help? Thanks!

  6. moshu
    Member
    Posted 6 years ago #

    I can't help: the site in your profile is going nowhere.

  7. toddorado
    Member
    Posted 6 years ago #

    Sorry - this it is now updated. Even when I enter http://www.ronkainen.org/blog, the extra 'blog' is added to the URL.

  8. moshu
    Member
    Posted 6 years ago #

    And what is in your admin > Options > General for the two URI values?

  9. toddorado
    Member
    Posted 6 years ago #

    I'm not sure I understand. Where specifically will I find these values?

  10. moshu
    Member
    Posted 6 years ago #

    Can you read?
    your admin > Options > General

  11. toddorado
    Member
    Posted 6 years ago #

    If you mean from my admin screen, can you read that I cannot get there? http://www.ronkainen.org/blog takes me to a 404 automatically: http://www.ronkainen.org/blog/blog. I do not know why it is appending the final 'blog' to the end. Thanks anyway. No need to be rude.

Topic Closed

This topic has been closed to new replies.

About this Topic