【发布时间】:2013-07-15 02:04:55
【问题描述】:
jQuery(function() {
jQuery('#rightbar').bind('mouseenter',function(){
jQuery(this).stop().animate({right: 0}, {duration:600});
});
jQuery('#rightbar').bind('mouseleave',function(){
jQuery(this).stop().animate({right: '-150px'}, {duration:600});
});
});
虽然我在我的网站上使用此功能,但它在除 Firefox(最新)之外的所有其他浏览器上都能正常工作。
当我将鼠标悬停在 div #rightbar 上时,它会像我的脚本一样向左移动而不是向右移动。 我检查了 Chrome 和 frefox:
在 Chrome 上,当鼠标悬停时,右属性从:-150 -> 0
但是在firefox上,当鼠标悬停时,右属性改变-150 -> -170 ...等..
不知道为什么,可能是firefox的bug(?)。
期待您的帮助。
谢谢!
P/s:您可以在这里查看:http://goo.gl/SChFo
【问题讨论】:
标签: jquery firefox jquery-animate