How to allow user to set destination folder for downloaded files(如何允许用户为下载的文件设置目标文件夹)
问题描述
在我的 Web 应用程序中有一个下载按钮,当用户单击它时,文件会下载到下载"文件夹.我想添加一个选项,用户可以选择下载文件的文件夹.
In my web application there is a download button, when user clicks on it a file gets downloaded to the "Downloads" folder. I want to add an option where user can select the folder in which the file should be downloaded.
我该怎么做?有没有可用的插件?
How can I do this? Is there any plugin available for this?
推荐答案
您将无法使用 javascript 或 jquery 选择用户的下载位置.这个只能从用户端设置,包含在浏览器上.否则会侵犯用户的安全.您可以建议的是文件名.阅读更多
You will not be able to choose the user's download location with javascript or jquery. This can only be set from the user's end, It contains on the browser. otherwise it would violate user's security. What you can suggest is the file's name. Read more
这篇关于如何允许用户为下载的文件设置目标文件夹的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持编程学习网!
本文标题为:如何允许用户为下载的文件设置目标文件夹


- 我不能使用 json 使用 react 向我的 web api 发出 Post 请求 2022-01-01
- 如何显示带有换行符的文本标签? 2022-01-01
- 是否可以将标志传递给 Gulp 以使其以不同的方式 2022-01-01
- 为什么我的页面无法在 Github 上加载? 2022-01-01
- 在不使用循环的情况下查找数字数组中的一项 2022-01-01
- 使用 iframe URL 的 jQuery UI 对话框 2022-01-01
- 为什么悬停在委托事件处理程序中不起作用? 2022-01-01
- 如何向 ipc 渲染器发送添加回调 2022-01-01
- 如何调试 CSS/Javascript 悬停问题 2022-01-01
- 从原点悬停时触发 translateY() 2022-01-01