WordPress.org

Support

Support » Themes and Templates » [Resolved] My comments aren't shown in the right post

[Resolved] My comments aren't shown in the right post

  • MSemlali
    Member

    @msemlali

    Hello,

    I am using a theme I created, and I’m having some problems with it.
    So, when I comment a post, then I go to “comments” in my wp-admin, I see that the comment wasn’t posted in the right post, it always go to another one.
    Another thing, the Disqus’ trackback URL always shows the link of other post.

    NB. I was using Disqus, then I tried LiveFyre and InteseDebate, and I still have the same problem =(

    NB. I don’t have this problem if I use other themes, so I think I have problems in mine, please help me to figure out how to fix this.

    Thank you =)

Viewing 8 replies - 1 through 8 (of 8 total)
  • Slobodan Manic
    Participant

    @slobodanmanic

    MSemlali, can you post a link to a page on your site where this occurs? Or, maybe you can try adding this just before your comments:

    <?php wp_reset_postdata(); ?>

    If you have any custom queries in your template, this might help.

    MSemlali
    Member

    @msemlali

    Ok I’ll try this.
    By the way, this is the website : http://followthegeeks.com

    Slobodan Manic
    Participant

    @slobodanmanic

    Site looks nice 🙂

    Which post is it exactly that’s giving you a headache? Or is it all of them?

    A wild guess is that either related posts or that LinkWithin widget is messing up WordPress default query.

    MSemlali
    Member

    @msemlali

    I try to deactivate both of them? right?

    Slobodan Manic
    Participant

    @slobodanmanic

    Well, if it’s easy to do it, I’d do that first.

    MSemlali
    Member

    @msemlali

    I think the problem is solved after deactivating the related posts. Now Disqus is showing the right trackback URL =D

    Thanks Slobodan Manic

    MSemlali
    Member

    @msemlali

    Ah by the way, I also added <?php wp_reset_postdata(); ?> to my single.php file, juste before <?php comments_template(); ?> =)

    Slobodan Manic
    Participant

    @slobodanmanic

    Glad I could help.

    You will probably still be able to use Related Posts if you add that code I posted, right after related posts function is called in your template.

Viewing 8 replies - 1 through 8 (of 8 total)
  • The topic ‘[Resolved] My comments aren't shown in the right post’ is closed to new replies.