title: php wont delete 775 dir chmod
body: <p>OK help me understand this.</p>
  
  <p>I have 2 users in my linux system that are BOTH part of "web-users" group.</p>
  
  <p>one is www-data used by the webserver and php-cgi
  one is my ftp-user</p>
  
  <p>when I upload files via ftp they are set to 775 for dirs and 664 for files, when I run a script on the server (so same group like the ftp user) to delete that directory and files inside: unlink for files works ok but the command rmdir doesnt work returning permission denied!? And yes the directory is deleted after is emptied.</p>
  
  <p>why is that 775 means that the group's user can delete it just like 664 for files.</p>
  
  <p>Thanks! </p>