title: how can I create a file with file_put_contents that has group write permissions?
body: <p>I am using <code>file_put_contents</code> to create a file. My php process is running in a group with permissions to write to the directory. When <code>file_put_contents</code> is called, however, the resulting file does not have group write permissions (it creates just fine the first time). This means that if I try to overwrite the file it fails because of a lack of permissions.</p>
  
  <p>Is there a way to create the file with group write permissions? </p>