Re: File Uploading

From: Date: Mon, 05 Feb 2001 07:30:38 +0000
Subject: Re: File Uploading
References: 1  Groups: php.windows 
Request: Send a blank email to php-windows+get-5372@lists.php.net to get a copy of this message
Randall, It looks as if your upload path AND the destination path for your uploaded files is the same, namely c:\temp; could that be the problem? Also, try setting the path to the full "c:\\temp" and make sure this directory exists ! "Randall Barber" <rdb55@email.byu.edu> a écrit dans le message news: 001801c08f0d$543bdcd0$42dfbb80@rdb55... I have scanned the archives (probably looking in the wrong place), and have tried the code in the documentation to no avail. I need help understanding the issues of file uploading using php. Here is the setup: PHP (ISAPI) installation. PHP.INI is in C:\WINNT the two DLLs are in C:\WINNT\SYSTEM32 (php4st.dll and msrcvt.dll) i think those are the names my entensions reside in C:\PHP\EXTENSIONS. My PATH variable includes this location. Here is the code: ---formtest.html--------------------------------- <html> <body> <form action="file-upload.php" method="post" enctype="multipart/form-data"> Send these files:<br> <input name="userfile[]" type="file"><br> <input name="userfile[]" type="file"><br> <input type='submit' value='Send Files'> </form> </body> </html> --file-upload.php-------------------------------- <html> <body> Files uploaded... <?php move_uploaded_file($userfile[0], "\\temp"); // Just move the first file. ?> </body> </html> I get one of two things happening: 1) I get two WARNINGS: Cannot open/create ([1] the file I uploaded, and [2] the target directory) or 2) No errors, no warnings, but also no file was copied to the C:\TEMP directory where I asked it to copy to. It is also never consistent. I either get the warnings with no result, or NO warnings with no result. In either case, I get no results. <frown>. I am on Win2k and FAT32 disk format. Therefore I don't have much directory/file security to worry about. Anyone help me please? This is my first look at PHP and I can see the power, but if it won't do what it is supposed to do, I don't see much use in it. Thanks in advance RDB

« previous php.windows (#5372) next »