CodeIgniter Forums
language uri and db routing - Printable Version

+- CodeIgniter Forums (https://forum.codeigniter.com)
+-- Forum: Archived Discussions (https://forum.codeigniter.com/forumdisplay.php?fid=20)
+--- Forum: Archived Development & Programming (https://forum.codeigniter.com/forumdisplay.php?fid=23)
+--- Thread: language uri and db routing (/showthread.php?tid=53080)



language uri and db routing - El Forum - 07-10-2012

[eluser]quasiperfect[/eluser]
hi

i have a routing problem

i have implemented a language uri solution based on examples from the forum

now my routes.php file looks like this

Code:
$route['default_controller'] = 'welcome';
$route['404_override'] = 'errors/page_missing';

$route['^(en|de|fr|it|es|ro)/(.+)$'] = "$2";
$route['^(en|de|fr|it|es|ro)$'] = $route['default_controller'];

my url's look like this domain-name.com/language/controller/etc


everything works great but now i want to add some routes based on db entries

building the routes.php from db and caching the routes is no problem but i have no ideea how and where to define the routes from the database so will work with the language uri solution

thanks in advance for any help

[bump]