I have a basic HTML form where the user can select files.
<input multiple type="file" name="file"/>
<input type="submit" name="submit" value="Submit" />
The user will be redirected to this form after clicking on a well specific button (present on the home page). Let's say I have 3 differents buttons.
If the user clicked on button1 I would like to redirect him to mysite/myform.php?var=button1
. I would also like to pre-fill the input file with a specific file located server-side : button1.txt
So I know which file is he wanting because of the URL and pick it with PHP code (server-side) and send it to the html page (with javascript).
Is it possible to fill in the form using this way?