my PHP script is using to register new user with his photo.
On Debian, everything was fine, but when I installed on my server RHEL, problems has begun.
Directory /tmp/ rights are 777 and "upload/" has 777 with chown apache:apache.
below is fragment of httpd's error_log:
[Wed Jun 07 15:25:29.363766 2017] [:error] [pid 22867] [client 10.31.242.73:49624] PHP Warning: move_uploaded_file(upload/1268_org.jpg): failed to open stream: Permission denied in /var/www/html/inc/classes/user.inc.php on line 76, referer: http://10.31.242.72/index2.php?mnu=10041
[Wed Jun 07 15:25:29.363808 2017] [:error] [pid 22867] [client 10.31.242.73:49624] PHP Warning: move_uploaded_file(): Unable to move '/tmp/phpmY6k8j' to 'upload/1268_org.jpg' in /var/www/html/inc/classes/user.inc.php on line 76, referer: http://10.31.242.72/index2.php?mnu=10041
I don't have any idea, what's wrong with it. Maybe I skipped something?