borlandology Posted June 3, 2010 Share Posted June 3, 2010 Hi I'm using a script and when i want to upload a picture is says: Warning: move_uploaded_file(/home/tomani/public_html/film/small/usa.png) [function.move-uploaded-file]: failed to open stream: No such file or directory in C:\xampp\htdocs\300tomani\admin\move.php on line 207 Warning: move_uploaded_file() [function.move-uploaded-file]: Unable to move 'C:\xampp\tmp\phpDB46.tmp' to '/home/tomani/public_html/film/small/usa.png' in C:\xampp\htdocs\300tomani\admin\move.php on line 207 the code is: move_uploaded_file($_FILES['F1']['tmp_name'], "/home/tomani/public_html/film/small/".$_FILES['F1']['name']); The "/home/tomani/public_html/film/small/" path does not exist because it is predefined. so i want to change it to work either on localhost (myPC) and on server (hosting), how? Thank you Link to comment https://forums.phpfreaks.com/topic/203729-move_uploaded_file-error/ Share on other sites More sharing options...
phpchamps Posted June 3, 2010 Share Posted June 3, 2010 just change this /home/tomani/public_html/film/small/ path and give your localhost or server's path... u must be knowing the path on your local/server.. then whts the prob?? Link to comment https://forums.phpfreaks.com/topic/203729-move_uploaded_file-error/#findComment-1067088 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.