- This topic has 26 replies, 3 voices, and was last updated 2 years, 7 months ago by Michael.
February 3, 2020 at 8:17 am #1153107Michael
I’ve just noticed that the anchor links in my Table of Contents disappear under the menu so that part of the answer text gets obscured initially. Is there any way I can somehow offset this so that when the link in the ToC is clicked it goes directly to the H2 header and keeps it visible (if you know what I mean?)February 3, 2020 at 8:21 am #1153114DavidStaffCustomer Support
You can use the GP Smooth Scroll option:
It will offset the sticky nav heigh when jumping to a link.February 3, 2020 at 9:16 am #1153168Michael
Yeah! Thanks David 🙂 I will look at that now 🙂February 3, 2020 at 9:23 am #1153174Michael
class="smooth-scroll"to the anchor links in my ToC on this page:
The Anchors are pointing to the IDs attached to each of the H2 sub-headings running down the page, but for some reason the offset and smooth scrolling doesn’t seem to be working? The Smooth Scroll option is checked in the Customizer General settingsFebruary 3, 2020 at 10:13 am #1153210DavidStaffCustomer SupportFebruary 3, 2020 at 12:18 pm #1153317Michael
It seems to be cutting off the H2 title and also a couple of the lines of description below. The anchor id is attached to the H2 so my understanding was that it would go to this and be visible? From what I can see the H2 is going right to the top of the page and the menu then covers it (I’ve cleared the cache and it’s still doing that)February 3, 2020 at 2:04 pm #1153390Michael
Hi David, I’ve been messing around with this for a little while now and it’s definitely not smooth scrolling for me, or allowing for any offset when it jumps to anchor ids. I’ve tried in Firefox and Chrome with the same result. So I must be missing something (again ;))February 3, 2020 at 4:50 pm #1153478TomLead DeveloperLead Developer
It’s working as it should for me: https://www.screencast.com/t/kLEm9dmr
Our smooth scroll and sticky navigation are built to work together as the video is showing.
What happens if you use incognito mode in your browser?February 4, 2020 at 12:30 am #1153689Michael
That looks like it’s working beautifully. Unfortunately not so for me. This is what I see (recorded on incognito page view on my laptop):
It jumps to the link ID without scrolling, and the offset is not working like yours either – the header and some of the description get hidden behind the menu.
I have cleared the browser cache, WordPress cache (the Optimizer plugin is turned off), and tried in different browsers and on my phone (and Nikki’s phone) but we get the same results.February 4, 2020 at 4:26 am #1153889DavidStaffCustomer Support
As Tom and I are both seeing it work correctly, i can only assume its a local issue.
There is a possibility that your Router or ISP is caching the site. Are you able to check the site using a different network ?February 5, 2020 at 6:56 am #1155517Michael
Hi David I’m at a friend’s house testing on their connection on my phone and the Bespoke page ToC is smooth scrolling. Weird. I’m not sure how to check caching settings on our router. But when I get home the day after tomorrow I will look into it and see what I can find on Google. Thanks both for your help and patience.February 5, 2020 at 7:42 am #1155573DavidStaffCustomer SupportFebruary 8, 2020 at 2:44 am #1158630Michael
I’m back home and the smooth scroll is still not working on my laptop. The router has been turned on and off. Any other ideas why it’s not working? Really weird. It’s working on my mobile, but not my laptop. I’m running Windows 10 if that makes any difference.February 8, 2020 at 3:22 am #1158646DavidStaffCustomer Support
Couple of things to try:
1. A different browser.
2. Disable any Browser extensions such as Ad blockers.
3. Right Click > Inspect the Page and see if any Red Errors are in the Console.
Before doing any of this make sure to clear any browser caches, and clear and disable any cache plugins.February 8, 2020 at 4:24 am #1158678Michael
Thanks for the suggestions. I’ve done as you suggested and the same thing happens in Opera and Firefox.
Here are the console messages in Firefox:
- You must be logged in to reply to this topic.