Mailing List Archive


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [tlug] Arrrg! Permissions driving me nuts in PHP [SOLVED]



> Does umask permissions take precedence over mkdir permissions? It might 
> be worth trying a umask 0 before the mkdir command.

Yes.

http://jp2.php.net/mkdir
http://jp2.php.net/umask

I think that fits the initial description of the problem; Dave, I'd be
interested to hear if this fixes it:
  $old=umask(0);
  mkdir($dirPath,0777);
  umask($old);

Darren

P.S. The comments on the above manual entries are interesting,
especially regarding security. But if you're using 777 then I assume
this doesn't need to be secure :-)


-- 
Darren Cook, Software Researcher/Developer

http://dcook.org/gobet/  (Shodan Go Bet - who will win?)
http://dcook.org/work/ (About me and my work)
http://dcook.org/blogs.html (My blogs and articles)


Home | Main Index | Thread Index

Home Page Mailing List Linux and Japan TLUG Members Links