Internet Explorer 中的 JQuery-ui 1.8.2 可拖动故障
我正在为我工作的公司维护 jquery/php 文件档案。
其中一项功能是将文件拖入文件夹的能力。此功能在 Chrome 和 FireFox 中都表现出色,但在 Internet Explorer 中表现出奇怪的行为。
发生的情况是,当在项目上启动拖动时,会创建一个选择矩形。预期的项目被拖动,并从其初始位置删除,因此在这方面插件正在工作。问题是,当选择框经过它们时,所有其他文件都会收到选择事件,这不仅不是有意的,而且也很难看。 我尝试在此处包含所有相关代码:
编辑:我也尝试将CSS作为pastebin包含在内,但作为我在这里的菜鸟,我只被允许创建一个链接
jquery和jquery-ui使用的版本分别是1.4.4和1.8.2
js文件中的第919行将文件div设为可拖动。 我在 google 上搜索了很多,还查看了 jquery 演示页面,其中可拖动界面按预期工作,也在 Internet Explorer 中。
我希望有人能够通过向我展示我的错误方式来帮助我逃离这个令人沮丧的跨浏览器兼容性地狱。
根据需要索取更多信息,我会尽力及时提供。
此致, 约翰·阿比尔兹科夫
I'm maintaining a jquery/php filearchive for the company I work at.
One of the features is the ability to drag files into folders. This functionality works wonders in both Chrome and FireFox but exhibits peculiar behaviour in Internet Explorer.
What happens is that when a drag is initiated on an item a selection rectangle is created. The intended item is dragged along, and removed from its initial position, so in that regard the plugin is working. The problem is that all the other files receive select events when the selection box passes over them, not only is this not intended, it is also ugly.
I have tried to include all the relevant code here:
Edit: I tried also including the css as a pastebin, but as the noob I am in here, I was only allowed to make one link
The versions used of jquery and jquery-ui is 1.4.4 and 1.8.2 respectively
The file divs are made draggable at line 919 in the js file.
I have googled quite a bit and also looked at the jquery demo pages, where the draggable interface works as intended, also in Internet Explorer.
I hope someone will be able to help me escape from this frustrating pit of cross-browser compatibility hell by means of showing me the way of my mistakes.
Request more information as needed, I will try to provide it in a timely manner.
Best regards,
Johan Abildskov
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
当我从一些可拖动的项目中删除可拖动时,问题实际上得到了解决。
看起来可拖动和可放置实际上在我们使用它的方式上有点冲突。
The issue was actually resolved when I removed draggable from some of the items also being draggable.
Seems draggable and droppable actually conflicted abit in the way we used it.