How do I give a PHP script permission to create temporary directories?

Question by boom.snap.clap.: How do I give a PHP script permission to create temporary directories?
I am running a Apache 2.2 PHP 5 Enabled server on my Windows 7 computer. I have a script that keeps throwing a ‘cannot create temporary directory’ exception. I need the equivelant of chmod(777) for it to work, is there any way I can get the same permissions as chmod(777) to ACL security?

Best answer:

Answer by Garren
two solutions:

#1 – make the directory yourself, right click it, and go to properties -> Under this panel, find the “Security” panel.

Under here, there are permissions – you’ll want to find the USER GROUP that the Program belongs to: I.E. System, Administrator, “Your User name Here”.

Then click on this group amd mofiy permissions and properties.

Or there should be a “Global” permissions –

The way it breaks down is like this.

the ‘Full Control’ box is equivalent to chmod 777

Then you’ll see the normal, read, write, and execute.

Make sure these are all checked.

Solution #2:

The exact same steps as above, but instead of making the directory yourself, right click on the ‘top-level’ directory that your program is trying to write to, and follow the security instructions outlined above.

Add your own answer in the comments!

Comments are closed.