Support » Fixing WordPress » All comments go to one post

Viewing 5 replies - 1 through 5 (of 5 total)
  • When I check the source of that post, I see this in the comments form:

    <input type="hidden" name="comment_post_ID" value="39" />

    Then checking on another post, I again see:

    <input type="hidden" name="comment_post_ID" value="39" />

    I assume the value has been (mistakenly) hardcoded. Change it to:

    value="<?php the_ID(); ?>"

    I checked it and I found this line:

    <input type=”hidden” name=”comment_post_ID” value=”<?php echo $post->ID; ?>” />

    The ID of the post where all comments are going is actually 39!!

    Then the task is to look at how your Recent Posts / Recent Topics are being generated. Considering Post #39 is presently the last one on both of these, one (or perhaps even both) are somehow overriding the $post object.

    Does a theme file decide it or is it decided out of the theme files?

    In other words, will changing the theme solve the problem??

    I can’t answer those questions directly, as I’ve no idea what is generating Recent Posts / Recent Topics. If these are components of the theme, then yes. If not (say they are plugins), it would depend on how they are incorporated in the pages.

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘All comments go to one post’ is closed to new replies.