Paul Ferrie wrote:I think i follow a bit. Can you give me more detail.
Since you're using "../dir/dir/".$file; for your path, I'm gathering it's a linux-based operating system. File's have varying permissions -- an 'la -ls' directory listing from the linux shell looks like this:
-rw-rw-r-- 1 wynder apache 534 Feb 2 16:14 test3.php
This means that wynder has read/write permissions (the first set of rw), apache (the user under which the web server is running) has read/write permissions and every other user can read the file.
If the 'w' was missing from that second set of permissions, apache (the web server) would be able to read that file but not write to it... including delete. If the permissions stayed as is, but instead read like this:
-rw-rw-r-- 1 wynder wynder 534 Feb 2 16:14 test3.php
Apache would be able to read the file (it's now using the last set of permissions, of which he only has read). That's really the best I can get into it without spawning this into a regular lecture, but if your path is right and your filename is right, chances are the permissions or ownership on your files are incorrect. When you login to the linux shell, these can be changed with the linux 'chmod' and 'chown' commands.