Route to redirect to a controller + an action by default on CodeIgniter?
问题 I'm currently working on a project with Codeigniter. I have one controller called Cat class Cat extends CI_Controller { function __construct(){ parent::__construct(); } function index($action){ // code here } } and a route (in routes.php) $route['cats/:any'] = 'cat/index/$1'; And that works if I use this URL for example: http://www.mywebsite.com/cats/display Nevertheless, if the user changes the URL to http://www.mywebsite.com/cats/ it doesn't work anymore. Codeigniter writes: 404 Page Not