RE: [PHP-GENERAL] file upload problem

From: Date: Wed, 07 Jun 2000 18:03:37 +0000
Subject: RE: [PHP-GENERAL] file upload problem
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-1238@lists.php.net to get a copy of this message
In your script to upload the file, you must immediately process the file otherwise it gets deleted. I've done this on Redhat. Here's a code example... <snip> //Recieve incoming upload and move to current directiory if (isset($file) && $file != "none") { if (!copy($file, $file_name.'.test')) { print("failed to copy $file...<br>\n"); } $file = "none"; } </snip> <snip html upload code> <form action="<? echo $PHP_SELF; ?>" enctype="multipart/form-data" method=POST> <input type="hidden" name="MAX_FILE_SIZE" value="1000000"> <input type="file" name="file"> <input type="submit" value="Upload File"> </form> </snip> Good Luck, Jason > -----Original Message----- > From: Kevin Beckford [mailto:kbeckford@bigorbit.com] > Sent: Wednesday, June 07, 2000 10:57 AM > To: GPHP > Subject: [PHP-GENERAL] file upload problem > > > I am using RH 6.0, and I am working with the file upload > functionality in PHP. > I tried to check the value of TMPDIR and it came up empty. I > tried uploading a > file and I cannot seem to find out where it has gone - I can access the > filename_name but the other properties are blank. What is happening? > ______________________________________ > Kevin Beckford > Programmer > Big Orbit - Specializing in new media for youth > www: http://www.bigorbit.com > email: kbeckford@bigorbit.com > [t] 416.516.0705 > [f] 416.516.9256 > > > -- > PHP General Mailing List (http://www.php.net/) > To unsubscribe, e-mail: php-general-unsubscribe@lists.php.net > For additional commands, e-mail: php-general-help@lists.php.net > To contact the list administrators, e-mail: php-list-admin@lists.php.net > > _______________________________________________________ Site Design, Hosting, and E-Commerce at www.webpipe.net

« previous php.general (#1238) next »