Friday, October 4, 2013

PHP Application File Permission - Linux ( Secured File Permission )

I suspect what you really want to do is set the directories to 755 and either leave the files alone or set them to 644. For this, you can use the find command. For

example:

To change all the directories to 755 (-rwxr-xr-x):
 
 find /opt/lampp/htdocs -type d -exec chmod 755 {} \;


To change all the files to 644 (-rw-r--r--):
 
 find /opt/lampp/htdocs -type f -exec chmod 644 {} \;

No comments:

Post a Comment