鼠标滚轮无法与 IE8 中的 jScrollPane 一起使用(没有 iframe!)
我在使用鼠标滚轮滚动 jScrollPane div 的内容时遇到问题,我似乎无法在 IE8 中工作。在 Chrome 中我工作正常。我对类似的问题感到愤怒,但这些情况的问题是使用了 iframe,但我不这样做。我包含了鼠标轮插件,据我所知,我已经正确设置了所有内容。
包含必要的文件:
<link type="text/css" rel="stylesheet" href="<?php echo base_url(); ?>assets/css/jquery.jscrollpane.css" />
<script type="text/javascript" src="<?php echo base_url(); ?>assets/js/libs/jquery-1.7.1.min.js"></script>
<script type="text/javascript" src="<?php echo base_url(); ?>assets/js/libs/jquery.mousewheel.js"></script>
<script type="text/javascript" src="<?php echo base_url(); ?>assets/js/libs/jquery.jscrollpane.min.js"></script>
应用 jScrollPane:
$("#chatlog").jScrollPane({
autoReinitialise: true,
autoReinitialiseDelay: 100,
maintainPosition: true,
stickToBottom: true,
verticalDragMinHeight: 13,
verticalDragMaxHeight: 13
});
CSS:
#chatlog {
position: relative;
height: 400px;
margin-bottom: 10px;
overflow-y: scroll;
}
我设置了一个非常简单的测试页,但存在此问题:
http://www.webtrail.nl/jscrollpane-example
谢谢!
I have and issue with scrolling content of a jScrollPane div using the mousewheel, which I don't seem to get working in IE8. In Chrome i'ts working correctly. I've red about simular issues but those cases the problem was with an iframe being used, which I don't. I included the mouswheel plugin and as far as I know I've set up everything correctly.
The inclusion of the necessary files:
<link type="text/css" rel="stylesheet" href="<?php echo base_url(); ?>assets/css/jquery.jscrollpane.css" />
<script type="text/javascript" src="<?php echo base_url(); ?>assets/js/libs/jquery-1.7.1.min.js"></script>
<script type="text/javascript" src="<?php echo base_url(); ?>assets/js/libs/jquery.mousewheel.js"></script>
<script type="text/javascript" src="<?php echo base_url(); ?>assets/js/libs/jquery.jscrollpane.min.js"></script>
Apply jScrollPane:
$("#chatlog").jScrollPane({
autoReinitialise: true,
autoReinitialiseDelay: 100,
maintainPosition: true,
stickToBottom: true,
verticalDragMinHeight: 13,
verticalDragMaxHeight: 13
});
CSS:
#chatlog {
position: relative;
height: 400px;
margin-bottom: 10px;
overflow-y: scroll;
}
I've set up a very simple testpage that has this issue:
http://www.webtrail.nl/jscrollpane-example
Thanks!
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
解决方案很简单。我已经下载并包含了最新版本的 jquery mousewheel 插件,问题已解决:
https:// /github.com/brandonaaron/jquery-mousewheel/downloads
Solution was simple. I've downloaded and included the newest version of the jquery mousewheel plugin and the problem was solved:
https://github.com/brandonaaron/jquery-mousewheel/downloads
我遇到了同样的问题,并将旧的 jquery 1.5 替换为 jquery 1.7,现在工作正常。
I had the same issue and replaced my old jquery 1.5 to jquery 1.7, now it's working fine.