I'm currently writing a script to upload images. I know I need to CHMOD the upload directory to 0755 before I try it or it won't work. So if I change the permissions to 0755 and use it, it works fine, and if I do another quite soon after it works also, but if i wait a while and try it again, it doesn't work (unable to open stream), and if I check the permissions of the folder they are set to 0.
The permissions keep resetting and I can't stop it from doing so!
I've even added
Code: Select all
chmod($uploaddir, 0755) or die('Couldn\'t change the persmissions on the upload directory.');Is this something to do with Apache or something else?
Thanks.