Skip to content

Instantly share code, notes, and snippets.

@tylerforret
Last active April 15, 2016 16:50
Show Gist options
  • Save tylerforret/b8708ae1f59853505ba4 to your computer and use it in GitHub Desktop.
Save tylerforret/b8708ae1f59853505ba4 to your computer and use it in GitHub Desktop.
CSS solution for jump/anchor link style menus with a fixed header that causes the jump to go to the wrong spot on the page.
@tylerforret
Copy link
Author

The name attribute is not supported in HTML5. Use the id attribute instead.

<a href="#goto">Jump</a>

<h2 id="goto">Header</h2>

Just using h2 as an example. Works with any tag.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment