Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我已经尝试过 HTML5 webkitdirectory 方法来上传指定目录中的所有文件。
<input type="file" name="files[]" id="files" multiple="" directory="" webkitdirectory="" />
但是,我只想要用户选择的目录中的文件名列表,而不是让浏览器将所有文件上传到服务器。
基本上,我想在客户端应用 scandir() 函数。有没有其他方法可以实现这一目标?
据我所知,您无法在客户端应用 scandir(),因为 PHP 是在服务器端执行的