# Local Anchor issue

**URL:** <https://discourse.mozilla.org/t/local-anchor-issue/24235>\
**Category:** MDN\
**Created:** [January 9, 2018, 9:07am UTC](https://discourse.mozilla.org/t/local-anchor-issue/24235 "2018-01-09T09:07:13Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![erosman](https://sea1.discourse-cdn.com/flex001/user_avatar/discourse.mozilla.org/erosman/32/15447_2.png) [@erosman](https://discourse.mozilla.org/u/erosman)\
**Post date:** [January 9, 2018, 9:07am UTC](https://discourse.mozilla.org/t/local-anchor-issue/24235/1 "2018-01-09T09:07:13Z")

</div>

I have noticed that the anchor doesn’t scroll to the correct location if clicked on the page.

Example:

> **[content\_security\_policy - Mozilla | MDN](https://developer.mozilla.org/en-US/docs/Mozilla/Add-ons/WebExtensions/manifest.json/content_security_policy)**
>
> Extensions have a content security policy (CSP) applied to them by default. The default policy restricts the sources from which extensions can load code (such as

Is there a reason?!

---

<div class="post-metadata">

**Author:** ![sheppy](https://sea1.discourse-cdn.com/flex001/user_avatar/discourse.mozilla.org/sheppy/32/20903_2.png) [@sheppy](https://discourse.mozilla.org/u/sheppy)\
**Post date:** [January 9, 2018, 3:11pm UTC](https://discourse.mozilla.org/t/local-anchor-issue/24235/2 "2018-01-09T15:11:13Z")

</div>

Not quite sure what you mean. It seems to have scrolled to the right place to me in this instance, given the link I’m seeing.

There is an issue where sometimes what you expect to be visible is not because it’s overlapped by the jump bar at the top of the page. That’s something that we already have a bug on file for, and it hopefully will be fixed before too long.

Sheppy

---

<div class="post-metadata">

**Author:** ![erosman](https://sea1.discourse-cdn.com/flex001/user_avatar/discourse.mozilla.org/erosman/32/15447_2.png) [@erosman](https://discourse.mozilla.org/u/erosman)\
**Post date:** [January 9, 2018, 3:28pm UTC](https://discourse.mozilla.org/t/local-anchor-issue/24235/3 "2018-01-09T15:28:13Z")

</div>

> [@sheppy](#):
>
> Not quite sure what you mean. It seems to have scrolled to the right place to me in this instance, given the link I’m seeing.

As mentioned, “I have noticed that the anchor doesn’t scroll to the correct location if clicked on the page.”

If you click the above link, it scrolls to the right place which is the start of the footnote.

If you go to `https://developer.mozilla.org/en-US/Add-ons/WebExtensions/manifest.json/content_security_policy` and then click on the `Allow remote scripts from "https://example.com": (see note 1 )` for me it scrolls passed the anchor so that the first line on top line visible is:

> extensions listed on [addons.mozilla.org](http://addons.mozilla.org) due to major security issues.

Note: I am on Firefox 59.0a1

---

<div class="post-metadata">

**Author:** ![jwhitlock](https://sea1.discourse-cdn.com/flex001/user_avatar/discourse.mozilla.org/jwhitlock/32/22480_2.png) [@jwhitlock](https://discourse.mozilla.org/u/jwhitlock)\
**Post date:** [January 10, 2018, 3:23pm UTC](https://discourse.mozilla.org/t/local-anchor-issue/24235/4 "2018-01-10T15:23:07Z")

</div>

If I follow the link to #exampleNote\_1, then I see this:

 ![00](https://us1.discourse-cdn.com/flex001/uploads/mozilla/original/3X/b/b/bbe69892a38576faf71e2ddfa5a48e2e17c6dfec.png)

If I hide the sticky table of contents (using developer tools, add a `visibility: hidden` attribute to `<div class="toc">`, then I see this:

 ![32](https://us1.discourse-cdn.com/flex001/uploads/mozilla/original/3X/0/6/06ea14c98749a2d67f04f99f0913b15ee915b0ae.png)

The anchor goes to the correct location, but the table of contents gets in the way. This is tracked in [bug 1424403](https://bugzilla.mozilla.org/show_bug.cgi?id=1424403).
