title: Apache does not have write permission on html folder
body: <p>I installed <code>apache</code>, <code>MySQL</code>, <code>PHP</code> in CentOS 7. All work well, except <code>apache</code> cannot write file in html folder. I found this problem when I used <code>file_put_contents</code>. I tried</p>
  
  <ol>
  <li>Change <code>owner</code> of <code>/var/www</code> to <code>apache:apache</code>, not work</li>
  <li>Added <code>Order allow,deny</code> <code>Allow from all</code> to <code>&lt;Directory "/var/www/html"&gt;</code> in <code>httpd.conf</code>, restart <code>httpd</code> service, not work</li>
  <li><code>chmod -R 0777 /var/www/html</code>, not work</li>
  </ol>
  
  <p>What is wrong with my server? Please help me!</p>
  
  <p>UPDATE1: result of <code>ls -al /var/www/html</code></p>
  
  <pre><code>total 40
  drwxrwxrwx.  5 apache apache 4096 Sep 23 10:19 .
  drwxr-x---.  4 apache apache   31 Sep 18 01:50 ..
  drwxrwxrwx. 15 apache apache 4096 Sep 23 08:43 folder1
  drwxrwxrwx+ 10 apache apache 4096 Sep 23 10:19 folder2
  -rwxrwxrwx.  1 apache apache 1574 Sep  5 08:55 favicon.ico
  -rwxrwxrwx.  1 apache apache  603 Sep 22 05:05 .htaccess
  -rwxrwxrwx.  1 apache apache 9841 Sep  8 08:34 index.php
  drwxrwxrwx.  8 apache apache 4096 Sep 23 08:44 folder3
  </code></pre>
  
  <p>UPDATE 2: apache <code>error_log</code> (I changed all IP address) - Edited, change to new error_log, after stop <code>httpd</code>, backup error_log, start <code>httpd</code></p>
  
  <pre><code>[Thu Sep 24 07:06:47.540295 2015] [core:notice] [pid 14439] SELinux policy enabled; httpd running as context system_u:system_r:httpd_t:s0
  [Thu Sep 24 07:06:47.541787 2015] [suexec:notice] [pid 14439] AH01232: suEXEC mechanism enabled (wrapper: /usr/sbin/suexec)
  [Thu Sep 24 07:06:47.569389 2015] [so:warn] [pid 14439] AH01574: module rewrite_module is already loaded, skipping
  [Thu Sep 24 07:06:47.572287 2015] [auth_digest:notice] [pid 14439] AH01757: generating secret for digest authentication ...
  [Thu Sep 24 07:06:47.573315 2015] [lbmethod_heartbeat:notice] [pid 14439] AH02282: No slotmem from mod_heartmonitor
  [Thu Sep 24 07:06:47.600913 2015] [mpm_prefork:notice] [pid 14439] AH00163: Apache/2.4.6 (CentOS) PHP/5.4.16 configured -- resuming normal operations
  [Thu Sep 24 07:06:47.600943 2015] [core:notice] [pid 14439] AH00094: Command line: '/usr/sbin/httpd -D FOREGROUND'
  </code></pre>