How to give apache permission to write to home directory?
PHP Snippet 1:
chmod 0777 /home/djameson/test.txt
PHP Snippet 2:
sudo chown www-data:www-data /home/djameson/test.txt
chmod 0744 /home/djameson/test.txt
PHP Snippet 3:
sudo usermod -a -G www-data djameson
chmod 0764 /home/djameson/test.txt
PHP Snippet 4:
chown -R apache /full-path-to-target-folder/
chcon -R -t httpd_sys_rw_content_t /full-path-to-target-folder/