CodeIgniter Forums
matchbox and admin sections : perfact modulation - Printable Version

+- CodeIgniter Forums (https://forum.codeigniter.com)
+-- Forum: Archived Discussions (https://forum.codeigniter.com/forumdisplay.php?fid=20)
+--- Forum: Archived General Discussion (https://forum.codeigniter.com/forumdisplay.php?fid=21)
+--- Thread: matchbox and admin sections : perfact modulation (/showthread.php?tid=31477)



matchbox and admin sections : perfact modulation - El Forum - 06-21-2010

[eluser]Unknown[/eluser]
Hi there,
So started using matchbox just now. but It will be better for me to have an module with its own admin section for this I want a modules structure like this

modules|
Module_1
site // this is front end folder
config
controllers
models
views
admin //admin section
config
controllers
models
views

now whenever I type uri index.php/module it should go to module/site and If I call index.php/admin/module it should go to module/admin folder.. looks like routes has to do something here but just not working for me.. can any one help here... thanks.. and yes please no mod_rewrite.. just the modifications in routes or whatever file is required



GOT ANSWER :::
just put the following line in application/config/route.php

$route['admin/([a-zA-Z_-]+)/(:any)'] = "$1/admin/$2";