title: Codeigniter hiding function name BUT keeping functionality
body: <p>I have a site with a default controller <code>home</code>. There is a login form on the home page, and pressing the login button calls the function <code>validate_credentials()</code>, a function in the home controller.</p>
  
  <p>When a user fails to enter correct login info, from within the <code>validate_credentials</code> function I call:</p>
  
  <pre><code>$this-&gt;index()
  </code></pre>
  
  <p>Which basically reloads the homepage, and fills in the email address form with the previous info.  I would call</p>
  
  <pre><code>redirect('home');
  </code></pre>
  
  <p>but then I cant pre-fill the email address form unless I create a session variable.</p>
  
  <p>After a user enters incorrect info, the url reads:</p>
  
  <p><code>http://www.example.com/home/validate_credentials</code></p>
  
  <p>I just want:</p>
  
  <p><code>http://www.example.com</code></p>
  
  <p>or even:</p>
  
  <p><code>http://www.example.com/home</code></p>
  
  <p>but using routes</p>
  
  <pre><code>$route['home'] = 'home/validate_credentials';
  </code></pre>
  
  <p>It actually changes the functions being called.  I just want to change the url.  Is this possible?</p>