Hi!
I have a folder, named 'file'. I upload files into this folder using a php script. I want only the php-script to have read/write/execute access to this folder, which means that if visiters of my website wants to download any of my uploaded files, they would have to go through another php-script, like download.php?fileid=4.
My problem is that in order to let my php-script have write access to the folder, I have to give everyone write-access. But then everyone can also directly access the files without going through the download.php-script, and I don't want that....
I guess I have missed some information here, but my question is this:
How can I let my php-script have read/write/execute access to a folder, while everyone else (others) have no access at all?
I have briefly heard about groups. Is there some way to define my script within a group, and then give this group read/write/execute access, while no access to others? If yes - how can I do this in practice? And how do I know how the "username" of the script? -Any examples?
PS: I don't have shell-access (ssh) to the server, so if I could do this through an FTP-client, that would be great!
Thank you :-)
Torbjørn