Dynamically set value of a file input
I have an input file HTML form and I want to set the initial value for the file path in an HTML form . I try to change tag "value" but it doesn't work anyway.
<input type="file" name="testcase" value= "C:\test.txt">
Please give me some advice for this small problem. Thanks.
From HTMLHelp.com :
The file input type creates a field through which users can upload files from their local computer or network. The VALUE attribute specifies the name of the initial file, but it is typically ignored by browsers as a security precaution.
Therefore, setting an initial value is not supported.
©2020 All rights reserved.