# How to put Discourse comments somewhere other than the default comment location?

**URL:** <https://meta.discourse.org/t/how-to-put-discourse-comments-somewhere-other-than-the-default-comment-location/152826>\
**Category:** WordPress\
**Created:** [26 mei 2020 om 20:41 UTC](https://meta.discourse.org/t/how-to-put-discourse-comments-somewhere-other-than-the-default-comment-location/152826 "2020-05-26T20:41:48Z")\
**Posts on this page:** 1\
**Showing post:** 5

<div class="post-metadata">

**Author:** ![avdi](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/avdi/32/105499_2.png) [@avdi](https://meta.discourse.org/u/avdi)\
**Post date:** [27 mei 2020 om 15:58 UTC](https://meta.discourse.org/t/how-to-put-discourse-comments-somewhere-other-than-the-default-comment-location/152826/5 "2020-05-27T15:58:00Z")

</div>

I wound up doing this, just referencing the postmeta without using any of the WP-Discourse code.

I was never able to get anything to work involving listing comments… all the functions I could find seem to want to return HTML with a bunch of {placeholders} in it 😕

```php
    $discuss_url = get_post_meta($post_id, 'discourse_permalink', true);
    $comment_count = get_post_meta($post_id, 'discourse_comments_count', true);
    if($discuss_url) {
        ?>
            <div class="lac-lesson-discuss">
                <a href="<?php echo $discuss_url ?>" target="lac_discuss">
                    💬 Discuss this! (<?php echo $comment_count ?> comments)
                </a>
            </div>
        <?php
    }

```

---

_[View the full topic](https://meta.discourse.org/t/how-to-put-discourse-comments-somewhere-other-than-the-default-comment-location/152826)._
