CodeIgniter Forums

Full Version: Upload folder permissions
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Hi...using Upload Folder Class, destination folder must have 777 permission. The thing is that in my production server, client wants all folders with 755 so, I can't change this. Is there any way that CI's Upload File Class works with this permissions?
Have you tried it with 755?
Yes I did, and the files does not upload. Also there is no error message...
(03-25-2015, 02:13 PM)jpleyjon Wrote: [ -> ]Yes I did, and the files does not upload. Also there is no error message...

Try the following:
  1. Change permissions on local server to 755
    If it will work locally, the problem will be somewhere else. If it will not work on local server, the problem is with permissions. If it is working on local server with CHMOD 755, the problem could be in paths.
  2. Check the paths to upload server
    I had similar problem. There was no error message, but the file was not uploaded. In my case, I had wrong path to upload directory. It worked on localhost, but not on production server. Try and check relative and absolute paths. It helped me, and it could be your problem too.
If the permissions are 755, the account for your web server (i.e. www-data) must be the owner of the upload directory to be able to add files to the directory.