Any folder than I want my php code to be able to save in or any file I want it to be able to modify has to be owned by www-data. This is annoying because everything I create or want to edit without sudo is owned by my user.On the other hand, my school's server shows everything being owned by the user but issues like this never happen. www-data seems to have no trouble saving or modifying things despite not being owner.How do I get my /var/www site working like this, where I can retain ownership of everything but not mess up www-data's access?
Give /var/www files access to www-data and my user?
permissions;users;webserver