Routing problem with Kohana 3.0
in my current project ive a controller tree like this:
Controller -
------Admin - ------------user.php ------otherClass.phpWhere controller and admin are folder and user and otherClass are the classes.
If i want to call any otherClass method the url would be this one:example.com/otherClass
But when i try to call the users methods like this:
example.com/admin/user
i get this : Class controller_admin does not exist (whats logical), so i tried with the routs in the bootstrap.php and after many failed tries, i gave up and decided to ask you guys :P .
The question is how should i code the route::set to make this wo开发者_JAVA技巧rk.
ThanksFirst thing is that you must set 'index_file' key to FALSE in bootstrap (when Kohana::init() is being called).
Leave the default route as it is ( it's controller/action/id, with controller and action being 'index' by default).
For more informations take a look at kohana 3 routing basics article
精彩评论