note 6278 modified in Uploading multiple files by ronabop
| From: | ronabop@php.net | Date: | Thu, 17 Aug 2000 09:28:12 +0000 |
| Subject: | note 6278 modified in Uploading multiple files by ronabop | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-2108@lists.php.net to get a copy of this message | ||
Funny, everyone seems to have problems with array uploading in php4... I have had no difficulties at
all with it... It could be that I enumerate all the file inputs like:<br><br>
<pre><input type="file"
name="uploadedfile[1]"></pre><br><br>
Then I just step through the array using <br><br>
<pre>while(list($key, $value) = each($uploadedfile)) {
copy($uploadedfile[$key], "/directory/" . $uploadedfile_name($key));
unlink($uploadedfile[$key]);
}</pre><br><br>
Seems to work well for me.
http://www.php.net/manual/uploading-multiple-files.php