When I am trying to edit files with the "fopen" command for example, I need to have permission to write to the file if I want to write to it via the web.
I know if I do something in cgi for example, it recognizes the script as being executed by My Username, so that only ppl via the web can change it or me. Or someone else that somehow got into my account.
Currently PHP is being recognized as 'www-data'. The problem is there are many sites on the server my website is on, that use PHP. So I can't just make PHP use my username.
Does anyone know how I could make PHP recognize the site it's being executed from (For example "http://yourserver.com/~yourusername" would make PHP use "yourusername" as the person executing the script) instead of www-data?