You are here

Change folders and subfolders permission through SSH

If you want to change the permission 755 to only directory present under the /home/user/public_html/subfolder then use following command

On shell

root@gunjan[~]#cd /home/user/public_html/subfolder
root@gunjan[/home/user/public_html/subfolder ]#find . -type d -exec chmod 755 {} \;

And if you want to change the permission 755 to only files present under the /home/user/public_html/subfolder then use following command

On shell

root@gunjan[~]#cd /home/user/public_html/subfolder
root@gunjan[/home/user/public_html/subfolder ]#find . -type f -exec chmod 755 {} \;
code type: