to upload from local drive to the local file system, we can use −
webkitdirectory attribute on c946df2939eb19165ad3e15299f6f1f8 − this allows the user to select a directory by the appropriate dialog box.filesystem api is a sandboxed filesystem, which allows us to store files on client’s machine.file api allows us to read files. files are accessible by c946df2939eb19165ad3e15299f6f1f8 elementall of the above is working fine in google chrome.
webkit directory is a much better option among these. use the following for directory −
webkitrequestfilesystem( window.temporary, 5 * 1024 * 1024, function(_fs) { fs = _fs; },err
上面,err和fs是−
var fs,err = function(err) { throw err;};
以上就是使用文件系统api将本地驱动器上的文件上传到本地文件系统的html中的详细内容。
