I have a script that creates a directory with CHMOD 777 like this:
$old_umask = umask(0);
mkdir("/my/absolute/path, 0777);
I have another script that suppose to be able to upload files in that directory.
The problem is that if I create a directory manually and set CHMOD 777 I am able to upload files, but if the directory is created with the first script, and I check and CHMOD IS 777 my second script spits an error and tells me to CHMOD that directory to 777...
Is there a bullet proof way of setting CHMOD while creating a new direcrtory?
Oh, yeh, my second script checks permissions like this:
if (!eregi("777",decoct(fileperms($mydir))))