Forums

The forums ran from 2008-2020 and are now closed and viewable here as an archive.

Home Forums CSS Fadein animations and anchor links Reply To: Fadein animations and anchor links

#239661
Shikkediel
Participant

It’s actually positioned correctly since it will scroll the element to the top of the page. To account for the header, you’ll need some JavaScript. Here’s a small script that’ll do a smooth transition :

Link

Then instead of this line :

scrollTop: target.offset().top

You could use this :

scrollTop: target.offset().top-$('header').outerHeight(true);