拖放* FROM *浏览器? [英] Drag and Drop *FROM* a browser?

查看:89
本文介绍了拖放* FROM *浏览器?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

将项目拖入浏览器已有很好的记录,而HTML5让这更容易。

Dragging items into a browser is pretty well documented, and HTML5 makes this easier.

但是,我想知道是否和如何可以从浏览器中拖拽

However, I'm wondering if and how it's possible to drag 'n' drop out of a browser.

在这种情况下,您将拥有一个网页元素(例如锚),用户将点击&将浏览器的 OUT 拖放到放置目标上,浏览器将直接将链接的对象(例如href'd文件)发送到放置目标,而不是启动通常的下载。

In this scenario, you'd have a webpage element (eg. an anchor) that the user would click & drag OUT of the browser onto a drop target, and the browser would send the linked object (eg. an href'd file) directly to the drop target instead of starting the usual download.

有人知道这是否可行?

推荐答案

可以在这里找到: http://www.thecssninja.com/javascript/gmail-dragout

这是一个关于如何将锚标签拖到桌面的说明,该文件将在那里下载。 (或者将锚标签拖到另一个应用程序上,操作系统将会适当地对待它。)

This is an explanation for how to drag an anchor tag to the desktop, and the file will be downloaded there. (Or drag the anchor tag onto another application, and the OS will treat it appropriately.)

我还没有想到,是如何拖放,通过HTML5删除多个链接(而不是一次只能一个),而无需使用像jquery这样的外部资源库。

What I haven't figured out yet, is how to drag-and-drop multiple links (instead of only one at a time) via HTML5, without having to resort to an external resource library like jquery.

这篇关于拖放* FROM *浏览器?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆