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.
是否可以对 HTML 文件输入进行编程以选择目录或卷中的特定文件。
单击文件输入按钮时,文件选择器打开,用户选择文件夹或拇指驱动器。然后在 jQuery 中,在所选目录中选择一个特定文件。
例如,用户在文件选择器中选择一个拇指驱动器,然后在提交表单时,只上传一个特定的(隐藏的)文件。
不,出于安全原因,这是不可能的。