Move uploadedfile error
Posted: Mon Jul 14, 2008 3:26 pm
First i am running PHP on a Windows2003 server
The error I receive is
Warning: move_uploaded_file(C:\Inetpub\Sites\test\secure\images\banner\test.jpg) [function.move-uploaded-file]: failed to open stream: No such file or directory in C:\Inetpub\test\test\admin\upload.php on line 16
Warning: move_uploaded_file() [function.move-uploaded-file]: Unable to move 'C:\WINDOWS\Temp\php97.tmp' to 'C:\Inetpub\Sites\test\secure\images\banner\222-fix.jpg' in C:\Inetpub\Sites\test\admin\upload.php on line 16
move to C:\Inetpub\Sites\test\secure\images\banner\222-fix.jpg failed
I'm sure I am missing something minor here. It looks like it is messing upthe tmp file name
Code: Select all
if (move_uploaded_file($_FILES['creative']['tmp_name'], "C:\Inetpub\Sites\test\secure\images\banner\\$filename"))
print "move successful to C:\Inetpub\Sites\test\test\images\banner\\$filename";
else
print "move to C:\Inetpub\Sites\test\secure\images\banner\\$filename failed";
The error I receive is
Warning: move_uploaded_file(C:\Inetpub\Sites\test\secure\images\banner\test.jpg) [function.move-uploaded-file]: failed to open stream: No such file or directory in C:\Inetpub\test\test\admin\upload.php on line 16
Warning: move_uploaded_file() [function.move-uploaded-file]: Unable to move 'C:\WINDOWS\Temp\php97.tmp' to 'C:\Inetpub\Sites\test\secure\images\banner\222-fix.jpg' in C:\Inetpub\Sites\test\admin\upload.php on line 16
move to C:\Inetpub\Sites\test\secure\images\banner\222-fix.jpg failed
I'm sure I am missing something minor here. It looks like it is messing upthe tmp file name