When i try to upload php file using vsftpd to /var/www/ and visit the file from web server i got this error,
Warning: Unknown: failed to open stream: Permission denied in Unknown on line 0
Fatal error: Unknown: Failed opening required '/var/www/.../.../public_html/d.php' (include_path='.:/usr/share/php:/usr/share/pear') in Unknown on line 0
i tried chown -R www-data:www-data /var/www after that the error got fixed but i have to do the same every time i upload a new file, is there is anyway to fix that for all new files?