|
|
|||||||||
|
|||||||||
| |||||||||
|
|
|
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
#1
|
|||
|
|||
|
Hello !
I've built a form for uploading a user file, it works for sure, and PHP3 is even telling the name of temporary file in specified directory - BUT there's no such file there! And I can't find it any where in the system. I'm using Apache 1.3 on Linux RH 6.0 Hedwig. So what could be a problem - please tell me. Thank you a priori! Yours, Thistle ------------------ Sincerely yours, =Thistle= |
|
#2
|
|||
|
|||
|
Did you check the file upload location on the server to make sure the web server has permission to write to the directory?
Also, wouldn't this message be more appropriate for the PHP forum? This is the Perl forum. [This message has been edited by Randy (edited 12-27-99).] |
|
#3
|
|||
|
|||
|
Best is to move your file in a non-temp location after it's been uploaded... Something like with the following code...
<BLOCKQUOTE><font size="1" face="Verdana,Arial,Helvetica">quote:</font><HR>if (!file_exists( "/destination_directory/$filename")) { copy($file, "/destination_directory/$filename"); } else { echo( "I'm sorry but your file name is already in use, please try another."); unlink($file); //deletes the temp file if it cannot be copied to destination exit; } unlink($file); //deletes the temp file after a succesfull copy to the destination if (!file_exists( "/destination_directory/$filename")) { echo( "Sorry but your file did not upload for some reason, please try again."); //makes sure the file is actually there... exit; }[/quote] I hope this helps! -Tricord BELGIUM URL [This message has been edited by Tricord (edited 12-28-99).] |
|
#4
|
|||
|
|||
|
THANK YOU, RANDY AND TRICORD!
THAT REALLY HELPED! Good Luck! |
![]() |
| Viewing: Dev Shed Forums > Programming Languages > PHP Development > HELP, PLEASE! UPLOAD WITH PHP3 - Got a problem here. |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|