# Reload page body when clicking a link in a custom header

**URL:** <https://meta.discourse.org/t/reload-page-body-when-clicking-a-link-in-a-custom-header/90543>\
**Category:** Product Support\
**Created:** [6월 23, 2018, 11:47오전 UTC](https://meta.discourse.org/t/reload-page-body-when-clicking-a-link-in-a-custom-header/90543 "2018-06-23T11:47:00Z")\
**Posts on this page:** 1\
**Showing post:** 7

<div class="post-metadata">

**Author:** ![Canapin](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/canapin/32/119591_2.png) [@Canapin](https://meta.discourse.org/u/Canapin)\
**Post date:** [6월 23, 2018, 3:36오후 UTC](https://meta.discourse.org/t/reload-page-body-when-clicking-a-link-in-a-custom-header/90543/7 "2018-06-23T15:36:44Z")

</div>

Hi, thanks for your reply.  
It doesn’t work, and here’s the output code on the page source:

```html
<script>Discourse._registerPluginCode('0.8.20', function (api) {

  $(function () {
    $("a.home-link").click(function () {
      console.log("test");
      require("discourse/lib/url").default.routeTo($(event.currentTarget).attr("href"));
      return false;
    });
  });
});</script>

```

---

_[View the full topic](https://meta.discourse.org/t/reload-page-body-when-clicking-a-link-in-a-custom-header/90543)._
