I'll ask this question with the preface, "still learning" Creating a simple one page site with page jumps (anchors) It is working well with the exception that when the page jumps the Header that I want to show is hiding under the sticky menu at the top of the page. How do I prevent this?
Thanks . Chuck
1 Answers
Hi Chuck,
Great question. Make sure your target element is actually at the top by checking its position in your web browser's “Inspector” or developer tools. In most browsers, you can right-click the element and then select, “Inspect” to view the underlying HTML code.
You might also just install the “Page scroll to id” plugin.
It replaces the default “jumping” behavior with a smooth scrolling animation, anytime anchor links with an href value containing, ‘#’ are clicked. Best of all, if your link’s URL is
#top
but no such target ID exists in your page, the plugin will scroll the page automatically to the very top (determined by the position of the body tag in the HTML).
You can see that plugin in action on our “Recommended WordPress Products” page.
That just may fix your issue.
Hope this helps!Thanks again Shawn. I’ll take a look at the plugin. The page does jump just fine back to the top. It’s when it jumps down that is the problem.
I just took a look. WOW! Now back to my full-time job before I get caught!