从 Web 应用程序访问本地文件
我正在研究是否可以让网络应用程序访问本地文件。该应用程序类似于文字处理程序,使得用户可以非常直接地打开/保存本地文件——他们会请求打开特定文件或将其保存到特定位置。
我读过一些文章称 Google Gears 可能允许这样做。但如果我没记错的话,我还读到 Google 停止了 Gears 的开发。
我还在某处读到 Adobe Air 允许这样做。虽然我没有空气。
我的希望是提供一个通用的编辑工具,可以访问存储在版本控制系统中的本地文件。用户可以在本地控制签入/签出,并使用编辑工具(可在公司网站上找到)打开这些文件。他们会修改它,将其保存回本地目录,然后在本地重新签入。
感谢您的任何提示!
I am looking into if it is possible to have a web application access local files. The application would be akin to a word processor metaphor, making the opening/saving of local files very direct on the user's part -- they would be requesting a specific file be opened or saved to a specific location.
I've read some that Google Gears might have allowed this. But if I remember correctly, I also read that Google discontinued development of Gears.
I've also read somewhere that Adobe Air allows this. I've not Air though.
My hope is provide a common editing tool that can access local files stored in a version control system. The user would have local control of checking in/out and would use the edit tool (available on the corporate web) to open those files. They'd modify it, save it back to the local directory and then locally check it back in.
Thanks for any tips!
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
您想要真正的文件处理还是文件加载/保存的隐喻?
只有少数浏览器支持传统
上传和超链接下载之外的实际文件处理。使用像Silverlight这样的插件,你可以做得更好,但你必须依赖插件。
如果您只想要隐喻,您可以将数据保存到本地存储或数据库并向用户显示隐喻。这会更容易,并且每个现代浏览器都支持这一点。
Do you want real file processing or the metaphor of file load/save?
Only a few browsers support real file processing beyond traditional
<input type="file" />
upload and hyperlink download. With plug-ins like Silverlight, you can do better but you have to rely on plug-ins.If you just want the metaphor, you can save your data to localStorage or database and show the metaphor to user. It will be easier and every modern browser supports this.