title: Htaccess - If/esle statement syntax for the main page
body: <p>I was wondering the correct syntax to check the main page (e.g. <code>abc.com</code> or <code>localhost</code>), for writing a <code>if/else</code> statement for the <code>.htaccess</code> file. Thanks.</p>
  
  <pre><code>&lt;If "abc.com" OR "localhost"&gt;
      &lt;FilesMatch "\.(css|js|txt)$"&gt;
          &lt;IfModule mod_expires.c&gt;
              ExpiresActive Off
          &lt;/IfModule&gt;
          &lt;IfModule mod_headers.c&gt;
              FileETag None
              Header unset ETag
              Header unset Pragma
              Header unset Cache-Control
              Header unset Last-Modified
              Header set Pragma "no-cache"
              Header set Cache-Control "max-age=0, no-cache, no-store, must-revalidate"
              Header set Expires "Mon, 10 Apr 1972 00:00:00 GMT"
          &lt;/IfModule&gt;
      &lt;/FilesMatch&gt;
  &lt;/If&gt;
  &lt;Else&gt;
      &lt;FilesMatch ".(css|jpg|jpeg|png|gif|js|ico)$"&gt;
          Header set Cache-Control "max-age=2592000, public"
      &lt;/FilesMatch&gt;
  &lt;/Else&gt;
  </code></pre>