3
I created a php application that uploads files (PDF, images and JSON) that works correctly on my PHP 5.2.17 server, but on the client server, the application only works if I change the site folder permission to 777.
On my server I use 755 for the folders and 644 for the files and everything works properly, there are no errors in the application on my server, I use upload move to load the files.
Someone has clues about what might be happening?
Perhaps some configuration of the client’s OS or server has already tried to reinstall Lamp/wamp/xampp?
– Costamilam
Probably the groups/users are different. Use
ls -ahl /path/to
orll /path/to
to check the user and the group to which the files belong.– Valdeir Psr
"Someone has clues about what might be happening?".. happening where?
– Sam
– dvd file upload does not work at the normal level of permission. Was that unclear? The upload only happens when I change the site folder permission to 777, which is against the default set by the client.
– Daniel Gomes Da Silva Moreira
The 755 permission will give write permission only to the owner of the folder. Usually who does this is apache. You need to give permission to the apache user of the apache group:
chown apache:apache -R /pasta/de/upload
– edson alves