I’m using WordPress and have created an own template. I use that template for a custom post type, which doesn’t present its ID correctly.
I have to use setup_postdata($better_lesson->post); to get the right post id (e.g. via echo).
Using comments_template(); however doesn’t save the comment under the specified post, but under the underlying site (wordpress page vs custom post).

Using custom_form() does the trick, but this way I cannot use Disqus, as it requires comments_template, to be shown.

Is there a way to tell comments_template to use a defined postId rather than using the standard one it receives automatically? As that should do the trick (I hope).


Read more here: WordPress comments_template() not showing comments for right ID


If you know the solution of this issue, please leave us a reply in Comment section, to update the question.

Wordpress related questions and answers: