Why to chmod ? Using suPHP or FastCGI you gonna notice that they need special permissions. In dso for example 777 is the default. Having those permissions using suPHP is first
- dangerous and secondly
- not recommended
Especially when almost all providers forbid 777 when using suPHP. So we need to change permissions at the maximum level suPHP allows us to do. That’s 755 for folders and files.
But it’s better when folders are 755 and files just 644. No need for other permissions.
How would I change all files to 644 and all folders to 755 using chmod from the linux command promt?
In case you are using SuPHP or FCGI you need a maximum of permissions 755.
Change it easily with this
# for directories: find . -type d -print0 | xargs -0 chmod 0755 # for files: find . -type f -print0 | xargs -0 chmod 0644