how to upload automatically a file to a web server
Posted on 2003-02-19
I know already how to upload a file with HTML thanks to the POST method. So everything works correctly except that i don't want the people to choose by their own the path of the file that will be uploaded to the server. I'd like that they are only able to press the submit button to accept the sending. So i tried to give to the Input a hidden type, and to give it also a value (here the path of the selected file). (the code is below) But this doesn't work yet...
I would appreciate that u could give me a useful help in order to get out of this problem.
<form method="post" action="recevoir.php" ENCTYPE="multipart/form-data">
<input type="hidden" name="MAX_FILE_SIZE" value="1000000000">
<input type="hidden" name="file_name" value="k:\projet\report.xml">
<input type="hidden" name="nomfic" value="report.xml">
<input TYPE="hidden" name="nomrep" VALUE="Report_stock/">
<input type="submit" name="submit" value="Transferer">