Tagged: 

Viewing 7 posts - 1 through 7 (of 7 total)
  • Author
    Posts
  • #1089978

    Hello Support,
    I have a site with a table of contents at the top that links to the headers in the content of the page by using anchor links. When I click on one of the links, the page scrolls to that header, but there is no offset, so that the header is hidden behind the transparent menu.

    I found posts about this issue at https://kriesi.at/support/topic/anchor-link-scroll-position/ and https://kriesi.at/support/topic/fix-scroll-position-anchor-link/, but none of the methods there seem to work for me.
    Looking at avia.js, line 631, “$.fn.avia_smoothscroll”, the code there does seem to attempt to calculate an offset, but again, it is not working in my case.
    Is there a way to fix this?

    • This topic was modified 5 years, 3 months ago by bodo.
    #1090004

    I just looked at an older version of my site in a virtual machine that was still running WordPress 4.9. With that, the anchor links are working correctly. When jumping to a header, there is an offset that will place the header under the menu so that it is not hidden.
    So this offset calculation seems to have been broken by WordPress 5.
    After upgrading my old site to WordPress 5, the offset is now also broken.

    • This reply was modified 5 years, 3 months ago by bodo.
    #1090279

    Hi,

    Sorry for the problem, I had a look at the anchor link you mentioned but it seems to scroll to the correct position on my end. Could you post a screenshot of what you are seeing on your end please?

    Best regards,
    Rikard

    #1090307

    I had deactivated sticky headers as a temporary workaround for the problem.
    I turned them on again, so please check the link again (perhaps after clearing your browser cache).

    #1090650

    Hi bodo,

    Can you disable caching and minification for now? There seems to be an error in the minified file.

    Best regards,
    Victoria

    #1092017

    Thanks, turning of minification of js has fixed it. Thanks for your help.

    #1092210

    Hi,

    I’m glad this was resolved. If you need additional help, please let us know here in the forums.

    Best regards,
    Jordan Shannon

Viewing 7 posts - 1 through 7 (of 7 total)
  • The topic ‘Jump to header with anchor link broken after upgrade to WordPress 5’ is closed to new replies.