WordPress.org

Ready to get started?Download WordPress

Forums

[resolved] erroneous /comment-page-1 in comment url generated after commenting (9 posts)

  1. maha-online
    Member
    Posted 5 years ago #

    When commenting on my blog, people get a 404 error, but the comment is there. The problem is that after commenting they are redirected to:

    http://www.maha-online.de/blog/<JJJJ>/<MM>/<DD>/<slug>/comment-page-1/#comment-<ID&gt;

    The part "/comment-page-1" is superfluous. With it, a 404 error occurs. The address should read:

    http://www.maha-online.de/blog/<JJJJ>/<MM>/<DD>/<slug>/#comment-<ID&gt;

    Any ideas?
    maha

  2. Dion Hulse
    WordPress Dev
    Posted 5 years ago #

    As of WordPress 2.7, WordPress supports Comment Paging, So the /comment-page-1/ refers to the first page worth of comments.

    However, It is a bit anoying it gets added even when the image would've been amongst the comments on the first page.

    If you're getting a 404 page, you might need to refresh your permalinks, Open the Permalink settings page, and click update, then see what happens

  3. maha-online
    Member
    Posted 5 years ago #

    Thanks for your comment. I updated .htaccess and commenting works fine!

  4. jdybka
    Member
    Posted 5 years ago #

    what did you add to .htaccess to resolve this?
    Thanks.

  5. dkusleika
    Member
    Posted 5 years ago #

    I disabled comments pagination under Settings - Discussion and that fixed it for me. So if you don't care if your comments are on pages, then that's an easy fix.

  6. lukep
    Member
    Posted 5 years ago #

    I was banging my head for weeks over this one... Thanks to dkusleika for mentioning that settings' location. Disabling pagination under Settings -> Discussion worked like a charm for me.

    Cheers!

  7. ourrug
    Member
    Posted 5 years ago #

    @maha-online to echo @jdybka's comment, what did you add to .htaccess to resolve this? i would like to take advantage of the new pagination features and not just turn it off. Can someone please explain?! Thanks.

  8. trentor
    Member
    Posted 5 years ago #

    I agree. I would like to actually use the pagination feature. What needs altered in .htaccess?

  9. Douglas Karr
    Member
    Posted 4 years ago #

    I was able to add a rewrite rule to my .htaccess file to strip the comment-page-1/ from the URL:
    RewriteRule ^(.*)/comment-page-1/ $1/ [R=301,L]

Topic Closed

This topic has been closed to new replies.

About this Topic