Skip to content
Advertisement

move_uploaded_file() Unable to move file from tmp to dir

I’ve been searching for the solution but I can’t find the answer.

I created a image upload form. It runs with ajaxform plugin. But still it doesn’t upload to the directory. The error_log says

move_uploaded_file() Unable to move file from [tmp] to [dir].

Then on the front end it says Upload Complete. But when the file is called, it doesn’t exist.

HTML CODE:

JavaScript

JS:

JavaScript

SEVER SIDE:

JavaScript

They are only found in one PHP file. Folder permission for the directory is 777.

Advertisement

Answer

Try this:

JavaScript
User contributions licensed under: CC BY-SA
10 People found this is helpful
Advertisement