WordPress.org

Ready to get started?Download WordPress

Forums

[resolved] Comments redirect (11 posts)

  1. Gautam Thapar
    Member
    Posted 3 years ago #

    How to make the user or anyone after leaving a comment to a post being redirected back to that comment ?

    My blog - http://www.hyipinvestigation.com

    Currently after posting a comment I am taken back to the top of the post.

  2. jkovis
    Member
    Posted 3 years ago #

    Each comments <li> tag has id="li-comment-<?php comment_id(); ">

    Remove the "li-comment-" part and it will work.

    Note: I don't know exactly what is inside the <?php ?> tags, but keep whatever it is and remove the li-comment-

  3. Gautam Thapar
    Member
    Posted 3 years ago #

    Thanks, I tried what you say but nothing happened, I stay at the top and not redirected back to the comment.

  4. Gautam Thapar
    Member
    Posted 2 years ago #

    Anyone else have any idea about this ?

  5. jkovis
    Member
    Posted 2 years ago #

    I just tried to take another look at your site but it's not loading right now.

  6. Gautam Thapar
    Member
    Posted 2 years ago #

    try now, it is working fine.

  7. jkovis
    Member
    Posted 2 years ago #

    Whoops, it looks like I told you to remove the wrong part...remove just the li- part, leaving comment-<?php comment_id(); ?>

    After leaving a comment you are redirected to http://yoursiteurl.com/#comment-#### where #### is the comment id.

  8. Gautam Thapar
    Member
    Posted 2 years ago #

    thanks, it worked but it takes me to the top portion of the comments section and not to the comment just posted.

  9. jkovis
    Member
    Posted 2 years ago #

    Find style.css in your theme and change:

    line 1078 from:

    .comment-body{
        float: left;
        padding: 8px;
    }

    to:

    .comment-body{
        /*float: left;/**/
        padding: 8px 8px 25px 8px;
    }

    There are some other CSS styles for .comment-body, but leave them as they are.

  10. Gautam Thapar
    Member
    Posted 2 years ago #

    Yeah now it is working perfectly fine, thank you so much :D

  11. jamminjames
    Member
    Posted 2 years ago #

    Is it possible to get this plugin to work with the Disqus comment system? I have it installed, and tried commenting, but nothing happens.

    Or is there an alternative that works with Disqus?

Topic Closed

This topic has been closed to new replies.

About this Topic

Tags