开发者

Prevent browser scrolling to hash on page load

Using localscroll on ready but the browser snaps to hash on ready. How do I prevent that and have it scroll to the top no matter what?

if this is not possible. How do you offset the position of the window.locati开发者_如何学运维on of hash?


Use $(window).scrollTop(0);

$(function(){
    $(window).scrollTop(0);
});
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜