title: how to remove function in url with .htaccess on codeigniter
body: <p>how to remove function controller in url with .htaccess.</p>
  
  <p>example</p>
  
  <pre><code>www.domain.com/controller/function/variable
  </code></pre>
  
  <p>to</p>
  
  <pre><code>www.domain.com/controller/variable
  </code></pre>
  
  <p>i try write the .htaccess file like this</p>
  
  <pre><code>&lt;IfModule mod_rewrite.c&gt;
      RewriteEngine On
      RewriteCond %{REQUEST_FILENAME} !-f
      RewriteCond %{REQUEST_FILENAME} !-d
      RewriteRule ^(.*)$ index.php/$1 [L] 
  
      RewriteRule ^index.php/catalog/([^./.]+)$ ./catalog/index/$1   
  &lt;/IfModule&gt;
  &lt;IfModule !mod_rewrite.c&gt;
      ErrorDocument 404 index.php
  &lt;/IfModule&gt;
  </code></pre>
  
  <p>catalog is controller and index is function</p>
  
  <p>but not works, it bring out the 404 page.</p>
  
  <p>thanks.</p>