I have a page with a tabbed interface. Each tab has a unique id. I've enabled links pointing to that page with the appended id after the hash, and I'm now trying to circumvent the default browser behavior that opens a URL with hash at the location of the element on the page.
So:
- pageA links to pageB like this:
<a
href="pageB.php#Tab4">Go</a>
- pageB opens, and my jQuery activates the correct tab, but the browser has scrolled down to where
<div id="Tab4">
is located on the page.
That's exactly what I want to prevent.
Any ideas?
Thanks!
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…