title: PHP errors not logged in separated log file
body: <p>I want to log apache2 and php errors in separated files:</p>
  
  <p>I create a directory in: <code>/var/log/apache2/mydomain.com</code>. this is the location where the log files are stored.</p>
  
  <p>I edited my <code>/etc/apache2/sites-available/mydomain.com.conf</code>:</p>
  
  <pre><code>&lt;VirtualHost *:80&gt;
  ServerName mydomain.com
  ServerAdmin webmaster@localhost
  ServerAlias mydomain.com
  DocumentRoot /var/www/mydomain.com/public
  
  php_flag display_errors Off
  php_flag log_errors On
  php_value log_errors_max_len 0
  php_value error_reporting 6135
  
  
  ErrorLog /var/log/apache2/mydomain.com/mydomain.com.error.log
  CustomLog /var/log/apache2/mydomain.com/mydomain.com.access.log common
  php_value error_log /var/log/apache2/mydomain.com/mydomain.com.php.error.log
  
  &lt;Directory "/var/www/mydomain.com/public"&gt;
      Options FollowSymLinks
      AllowOverride All
  &lt;/Directory&gt;    
  </code></pre>
  
  <p></p>
  
  <p>Important settings:</p>
  
  <ul>
  <li>php_flag display_errors Off</li>
  <li>php_flag log_errors On</li>
  <li>php_value log_errors_max_len 0</li>
  <li>php_value error_reporting 6135</li>
  <li>php_value error_log /var/log/apache2/mydomain.com/mydomain.com.php.error.log</li>
  </ul>
  
  <p>But the file: <code>mydomain.com.php.error.log</code> is not created, instead all the PHP errors are added to the mydomain.com.error.log file.</p>
  
  <p>apache2 is able to write in the directory: <code>/var/log/mydomain.com</code> (tested, if i remove the file: <code>mydomain.com.error.log</code>. it will be recreated)</p>
  
  <p>there are no log related settings in my <code>.htaccess</code> file:</p>
  
  <pre><code>RewriteEngine On
  RewriteCond %{REQUEST_FILENAME} -s [OR]
  RewriteCond %{REQUEST_FILENAME} -l [OR]
  RewriteCond %{REQUEST_FILENAME} -d
  RewriteRule ^.*$ - [NC,L]
  RewriteCond %{REQUEST_URI}::$1 ^(/.+)(.+)::\2$
  RewriteRule ^(.*) - [E=BASE:%1]
  RewriteRule ^(.*)$ %{ENV:BASE}index.php [NC,L]
  </code></pre>
  
  <p>when i edit the <code>/etc/apache2/sites-available/mydomain.conf</code> file, i run: <code>sudo service apache2 restart</code> afterwards.</p>
  
  <p>Do you see anything that is wrong or is there a reason why it might not work?</p>