RE: [PHP-WIN] upload_tmp_dir = c:\php\uploads

From: Date: Tue, 25 Jul 2000 16:29:57 +0000
Subject: RE: [PHP-WIN] upload_tmp_dir = c:\php\uploads
References: 1  Groups: php.windows 
Request: Send a blank email to php-windows+get-1308@lists.php.net to get a copy of this message
You could try putting the directory name in quotes... -----Original Message----- From: Dave Johnston [mailto:davjoh@interlog.com] Sent: 25 July 2000 16:46 To: PHPWindowsList Subject: [PHP-WIN] upload_tmp_dir = c:\php\uploads upload_tmp_dir = c:\php\uploads The following error will show that the above setting is being ignored. ************************************** You submitted this file: Name: C:\\WINDOWS\\TEMP\\php2 Original Name: Ad.txt Size: 606 Type: text/plain Warning: Unable to open 'C:\\WINDOWS\\TEMP\\php2' for reading: Unknown error in c:\Inetpub\wwwroot/upload.php3 on line 11 Error: failed to copy file... ************************************** The following 2 files are the generators. <html> <!-- upload.htm --> <form action = "upload.php3" method = "post" enctype = "multipart/form-data"> submit this file: <input type = "file" name = "userfile" ><br> <input type = submit><BR> </form> </html> <html> <!-- upload.php3 --> You submitted this file:<BR><BR> Name: <? echo($userfile); ?><BR> Original Name: <? echo ($userfile_name); ?> <BR> Size: <? echo($userfile_size); ?><BR> Type: <? echo($userfile_type); ?><BR> <? //Copy the file to C:\upload.txt. Remember to escape backslashes! if (copy($userfile, "c:\\upload.txt")) { echo ("File successfully copied!"); }else { echo ("Error: failed to copy file..."); } //unlink ($userfile); ?> </html> Why does the variable &userfile contain "C:\\WINDOWS\\TEMP\\php2" with double backslashes? Why is the setting to store uploaded files in the .ini file being ignored or over-ridden by the system default? Help greatly appreciated! Dave -- PHP Windows Mailing List (http://www.php.net/) To unsubscribe, e-mail: php-windows-unsubscribe@lists.php.net For additional commands, e-mail: php-windows-help@lists.php.net To contact the list administrators, e-mail: php-list-admin@lists.php.net

« previous php.windows (#1308) next »