title: Setting up admin panel in Codeigniter
body: <p>In my project I am trying to create one section for admin. Following <a href="http://philsturgeon.co.uk/blog/2009/07/Create-an-Admin-panel-with-CodeIgniter#top" rel="nofollow">http://philsturgeon.co.uk/blog/2009/07/Create-an-Admin-panel-with-CodeIgniter#top</a> I tried the second method. According to it, my folder structure is changed to somewhat like this.</p>
  
  <pre><code>project
     cache
     config
     controllers
         -admin
            index.php
         -blog.php
     system
     views
         -admin
            index.php
          blog.php
  ...................
  </code></pre>
  
  <p>I have created one controller <em>index.php</em> inside <em>controllers/admin</em> with following code:</p>
  
  <pre><code>class Index extends CI_Controller
  {
      function __construct()
      {
          parent::__construct();
      }
  
      function index()
      {
          $this-&gt;load-&gt;view(index/index);
      }
  }
  </code></pre>
  
  <p>And inside <em>views/admin</em> I have created a file <em>index.php</em> and echoed some string and in <em>routes.php</em> I have added this line,</p>
  
  <pre><code>$route['admin'] = 'admin/index';
  </code></pre>
  
  <p>But when I run the admin panel using the url, <code>http://localhost/workspace/project/admin/</code>, I am getting the 404 error</p>
  
  <pre><code>The requested URL /workspace/project/admin/ was not found on this server.
  </code></pre>
  
  <p>What I am doing wrong? Is there any other settings I have to make.</p>
  
  <p>Can someone please guide me to fix this ? I am new to Codeigniter.</p>
  
  <p>Thanks in advance.</p>