i am new to linux platform and now i wanted to remove write permissions of all the php files unde开发者_如何学Gor my root folder. It would be appreciable if somebody can suggest a solution.
thanks and regards
tismon
find / -name '*.php' -exec chmod a-w {} \;
An alternate option would be to use these 2 commands
cd /
chmod -R a-w *.php
But I also recommend (like Matthieu did) to have a look first, what files you are really modifying.
This will work:
find /root -type f -name "*php" | xargs chmod 664
精彩评论