title: Using .htaccess to redirect /sitemap.xml to /index.php/sitemap/
body: <p>I'm using codeigniter to generate a page that contains XML data. The URL of the file is located at /index.php/sitemap, but I want the URL to be accessed via /sitemap.xml </p>
  
  <p>My <code>.htaccess</code> file is already modified to allow users to access URLs without entering /index.php/ before URLs. This is the <code>.htacess</code> file I'm using:</p>
  
  <pre><code>RewriteEngine On
  
  RewriteCond %{REQUEST_FILENAME} -s [OR]
  RewriteCond %{REQUEST_FILENAME} -l [OR]
  RewriteCond %{REQUEST_FILENAME} -d
  RewriteRule ^.*$ - [NC,L]
  RewriteRule ^.*$ index.php [NC,L]
  
  RewriteRule ^sitemap\.xml$ index.php/sitemap [L]
  </code></pre>
  
  <p>Everything is working fine, except the redirection of the sitemap.xml file. I'm on a windows machine running XAMPP</p>
  
  <p>What am I doing wrong?</p>