ubuntu - all files such as name, size and type using PHP are clearly correct but the files unable to move to real folder -


i little bit confuse , have headache find upload file problem. have php script contained simple code of uploading file. below script:

$file_path = "doc_student/"; $image = $final_save_dir . $_files['uploadfile']['name'];  if($_files['uploadfile']['error'] > 0): echo "error: " . $_files['uploadfile']['error']. "<br>"; else: echo "upload: " .$_files['uploadfile']['name'] . "<br>"; echo "type: " .$_files['uploadfile']['type'] . "<br>"; echo "size: " .($_files['uploadfile']['size'] / 1024) . "kb<br>"; echo "stored in: " .move_uploaded_file($_files['uploadfile']['tmp_name'], $file_path . $_files['uploadfile']['name']) . "<br>"; endif; 

everything's worked fine except file upload not move $file_path = "doc_student/".

one of friend told me give proper permission allow files upload folder given below how give permission in ubuntu?

use chown or chmod, chmod -r 777 doc_sudent easy not safe. chown -r owner.group doc_sudent, owner , group should run user , group of php


Comments

Popular posts from this blog

google api - Incomplete response from Gmail API threads.list -

Installing Android SQLite Asset Helper -

Qt Creator - Searching files with Locator including folder -