禁用滚动条和鼠标滚轮但不滚动

时间:2013-05-13 17:56:22

标签: javascript jquery css

如何在网站中隐藏滚动条,禁用鼠标滚动但能够使用jquery scrollTo插件功能到达页面的隐藏区域? (单击按钮,页面滚动到目标元素)?

谢谢!

1 个答案:

答案 0 :(得分:2)

要禁用滚动条,请使用简单的css:

html, body {
    overflow:hidden;
}

要滚动,请查看此示例:

http://www.adriantomic.se/development/scroll-to-the-top-with-jquery/

相关问题