Hi
I have this path stored in a variable $path:
$path = "../images/colour/class1/";
When i upload images to this path, it always fails unless the chmod is set to 0777. Its default is 0644.
I thought it would be a good idea to change the chmod to 0777 at the point of uploading so I have this code but it does not work:
$path = "../images/colour/class1/";
chmod("$path", 0777);
// upload the image here...
chmod("$path", 0644);
Can anyone suggest reasons why the folder permissions are not being changed?
Thanks in advance