Error when trying to upload file in PHP -


By the morning I am doing all the work right php page. The page is not uploading any selected file anymore. Whatever I receive, the following error message is:

WARNING: move_uploaded_file (upload / brainstream_2009_06_25_23041.zip) [function.move-uploaded-file]: failed to open the stream: such In a file or directory, c: \ xampp \ htdocs \ vectorization \ admin \ jobs_edit.php on line 146

Warning: move_uploaded_file () [function.move-uploaded-file]: 'C: \ documents and C: \ xampp \ htdocs \ vectorization \ admin \ jobs_edit.php The row 146 file could not be uploaded to Settings \ Admin \ Local Settings \ Temp \ php1B2.tmp 'to' upload / brainstream_2009_06_25_23041.zip '. Please select a valid file file name: BrainStream.zip

I have written the following code:

  $ uplfile = $ _FILES ['uploadfile'] [ 'Name']; $ Upltmp = $ _FILES ["UploadFile"] ["tmp_name"]; If ($ ($ uplfile)) {$ ext = explosion (".", $ Uplfile); $ Upload_data = date ("Y_m_d"); // To avoid conflict with the same name, use this variable to rename the file name $ upload_dir = "upload /"; $ File_name = $ ext [0]. "_". $ Upload_data "_". RAND (0, GRindMax ()). "." $ Ext [1]; I have installed the XAMPP stack on my PC which is running WinXP, which has 3 GB RAM and enough hard disk space.  

/ P>

No matter what size file I select, it always returns an error.

What should be wrong with this code? Interesting syntax error in the last line indicates that the problem is in that line and either the source file or the

Destination directory is missing. Since the first one is automatically generated, make sure C: \ xampp \ htdocs \ vectorization \ admin \ upload \ / code> is present and is writeable.


Comments

Popular posts from this blog

c++ - Linux and clipboard -

What is expire header and how to achive them in ASP.NET and PHP? -

sql server - How can I determine which of my SQL 2005 statistics are unused? -