Uploading files

From: Date: Fri, 29 Jun 2001 17:40:37 +0000
Subject: Uploading files
Groups: php.general 
Request: Send a blank email to php-general+get-55586@lists.php.net to get a copy of this message
Okay, I'm absolutely certain that there's a simple solution to my problem, but my forehead is getting sore from banging it against the wall, so I thought I'd pick y'all's brains. I'm using a form to upload a number of files named $input_form_$i where $i is from 0 to 5 and the following is my code: for ($i = 0; $i<=5; $i++){ $l = "input_form_$i"; $location = $$l; move_uploaded_file($location, "$upload_path/$location_name"); } with that, I get the following warnings: Warning: Unable to create '/': Invalid argument in [php file running program] on line 64 Warning: Unable to move '/var/tmp//php9Uai9S' to '/' in [php file running program] on line 64 /var/tmp//php9Uai9S not loadable Funny thing is another page that doesn't use the $$l method to dynamically grab variable names (just uses a static variable name) works totally fine with essentially the same code. FYI: The form type is "multipart/form-data" and the input fields are set to "file" so I have no idea what's going wrong. Any thoughts? David Castillo Application Systems Analyst Human Resources Department Northern Arizona University outpost7@hotmail.com

« previous php.general (#55586) next »