简体   繁体   English

JavaScript库上传文件

[英]JavaScript library to upload a file

是否有一个图书馆可以让我下载用户的个人资料照片并上传?

If you want to just retrieve the file then you are best off just using an img tag and changing where it points to, but, if you want to access the hard drive of the user, it really depends on how limited of browser support you want. 如果只想检索文件,则最好只使用img标记并更改其指向的位置,但是,如果要访问用户的硬盘驱动器,则实际上取决于想要的浏览器支持的限制程度。

You may want to look at DOM Storage though. 您可能想看看DOM存储。

These links may help: http://msdn.microsoft.com/en-us/library/cc197062(v=VS.85).aspx 这些链接可能会有所帮助: http : //msdn.microsoft.com/zh-cn/library/cc197062(v=VS.85).aspx

https://developer.mozilla.org/en/DOM/Storage#localStorage https://developer.mozilla.org/en/DOM/Storage#localStorage

In Firefox 3.6 they added a File API: https://developer.mozilla.org/en/Using_files_from_web_applications 在Firefox 3.6中,他们添加了文件API: https : //developer.mozilla.org/en/Using_files_from_web_applications

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM