title: CodeIgniter 404 error on controller/method routes
body: <p>I'm facing a little problem right now with CodeIgniter...</p>
  
  <p>I have the following file :</p>
  
  <pre><code>applications/controllers/home/entretiens.php
  </code></pre>
  
  <p>Which looks like this :</p>
  
  <pre><code>&lt;?php if ( ! defined('BASEPATH')) exit('No direct script access allowed');
  
  class Entretiens extends CI_Controller
  {
      public function index()
      {
          if($this-&gt;session-&gt;userdata('logged_in'))
          {
               $data['page'] = "entretiens";
               $session_data = $this-&gt;session-&gt;userdata('logged_in');
               $data['prenom'] = $session_data['prenom'];
               $this-&gt;load-&gt;model("Entretiens_model");
               $data['entretiens'] = $this-&gt;Entretiens_model-&gt;getAllEntretiens($session_data['id']);
               $data['main_content'] = 'home/entretiens_view.php';
               $this-&gt;load-&gt;template('entretiens_view', $data);
          }
          else
          {
              //If no session, redirect to login page
              redirect('home/login', 'refresh');
          }
      }
  
      public function ajouter()
      {
          echo 'Test';
      }
  }
  
  ?&gt;
  </code></pre>
  
  <p>If I go with my browser on : <code>myurl/entretiens</code> I get the right page (the index method of the controller "entretiens"), but if I go to <code>myurl/entretiens/ajouter</code> all I get is a 404 from CodeIgniter.</p>
  
  <p>Here's my routes file :</p>
  
  <pre><code>$route['default_controller'] = "home/index_controller";
  $route['login'] = "home/login_controller";
  $route['user'] = "home/user_controller";
  $route['entretiens'] = "home/entretiens";
  $route['404_override'] = '';
  </code></pre>
  
  <p>And the <code>config.php</code> (well, the interesting parts) :</p>
  
  <pre><code>$config['base_url'] = 'http://dev.hinsolite.com/';
  $config['index_page'] = '';
  $config['uri_protocol'] = 'AUTO';
  </code></pre>
  
  <p>And my <code>.htaccess</code> :</p>
  
  <pre><code>RewriteEngine on
  RewriteCond %{SCRIPT_FILENAME} !-d
  RewriteCond %{SCRIPT_FILENAME} !-f
  RewriteCond $1 !^(index\.php|css|images|robots\.txt)
  RewriteRule ^(.*)$ ./index.php/$1 [L]
  </code></pre>
  
  <p>(This problem is on all the controlers, and not only <code>entretiens</code>...</p>