# Embedded topic comments are missing if containing page's URL includes a fragment identifier

**URL:** https://meta.discourse.org/t/embedded-topic-comments-are-missing-if-containing-pages-url-includes-a-fragment-identifier/93235
**Category:** Bug
**Created:** [July 26, 2018, 9:00pm UTC](https://meta.discourse.org/t/embedded-topic-comments-are-missing-if-containing-pages-url-includes-a-fragment-identifier/93235 "2018-07-26T21:00:39Z")
**Posts on this page:** 1
**Showing post:** 2

<div class="post-metadata">

### Author: ![vinothkannans](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/vinothkannans/32/86465_2.png) [@vinothkannans](https://meta.discourse.org/u/vinothkannans)
#### Post date: [July 26, 2018, 9:32pm UTC](https://meta.discourse.org/t/embedded-topic-comments-are-missing-if-containing-pages-url-includes-a-fragment-identifier/93235/2 "2018-07-26T21:32:31Z")

</div>

> [@discourseEmbedUrl and Joomla](https://meta.discourse.org/t/discourseembedurl-and-joomla/92039/2):
>
> You can use the below code. It will remove the query string from URL.
> 
> `discourseEmbedUrl: window.location.href.split(/[?#]/)[0] };`

The above solution may help you. It will remove query strings too. So you have to remove the `?` character. Anyway I will check your suggestion. If you can create a PR that will be more helpful.

---

_[View the full topic](https://meta.discourse.org/t/embedded-topic-comments-are-missing-if-containing-pages-url-includes-a-fragment-identifier/93235)._
