Codeigniter Changing routes makes $this->uri->segment() not working
<p>I've altered routes.php </p>

<pre><code>$route['category']='Home/category';
</code></pre>

<p>for making url look like www.website.com/category insteead of www.website.com/Home/category. Since Home is my default controller.
but if i am using <code>$this-&gt;uri-&gt;segment();</code> inside category function, its not working. this is my controller</p>

<pre><code>class Home extends CI_Controller {

  public function category()
  {
     $value=$this-&gt;uri-&gt;segmet(3);
  }
}
</code></pre>

<p>And my url is <code>www.website.com/category/books</code>
I am getting result if I dont alter routes. But by altering routes, I need this to work. Please help me. Thanks</p>