upload files

From: Date: Fri, 25 Oct 2002 22:11:47 +0000
Subject: upload files
Groups: php.general 
Request: Send a blank email to php-general+get-121489@lists.php.net to get a copy of this message
Hello everybody, I want to allow the client to upload a text file on my web server, so I use this code : <html> <head></head> <body> Uploaded files details<br> <?php printf("Name : %s <br>", $HTTP_POST_FILES["userfile"]["name"]); printf("Temporary Name : %s <br>", $HTTP_POST_FILES["userfile"]["tmp_name"]); printf("Size : %s <br>", $HTTP_POST_FILES["userfile"]["size"]); printf("Type : %s <br>", $HTTP_POST_FILES["userfile"]["type"]); if (copy ($HTTP_POST_FILES["userfile"]["tmp_name"],"temp/".$HTTP_POST_FILES["userfile "]["name"])) { printf("File successfully copied");} else{ printf("Error: failed to copy file");} ?> </body> </html> the $http_post_files doesn't return me anything, anybody would have a clue ?? ( roughly speaking I am not able to retrieve the field the client try to send me). Thanks a lot.

« previous php.general (#121489) next »