RE: [PHP-WINDOWS] How I got PHP under Windows to upload a file

From: Date: Tue, 27 Jun 2000 12:43:14 +0000
Subject: RE: [PHP-WINDOWS] How I got PHP under Windows to upload a file
Groups: php.windows 
Request: Send a blank email to php-windows+get-687@lists.php.net to get a copy of this message
Using Windows NT, Apache, PHP4, I did have some trouble at first. I discovered that the problem was with the current directory. So if I used: copy ($uploadedfile, "c:\\$uploadedfile_name"); for example, this did not work because the current directory was not the same as the temporary directoy. The temporary directory is set with $TEMPDIR. What I do now is set the directory for uploads with the upload_tmp_dir variable in the php.ini file explicitly. Then I use: copy ("$upload_tmp_dir$photofile", "c:\\$uploadedfile_name"); ...which does the trick nicely. __________________________________________________ Do You Yahoo!? Get Yahoo! Mail - Free email you can access from anywhere! http://mail.yahoo.com/

« previous php.windows (#687) next »