![]() |
Internationalization (i18n) library for CodeIgniter 2 problem with routing - Printable Version +- CodeIgniter Forums (https://forum.codeigniter.com) +-- Forum: Archived Discussions (https://forum.codeigniter.com/forumdisplay.php?fid=20) +--- Forum: Archived Libraries & Helpers (https://forum.codeigniter.com/forumdisplay.php?fid=22) +--- Thread: Internationalization (i18n) library for CodeIgniter 2 problem with routing (/showthread.php?tid=52559) |
Internationalization (i18n) library for CodeIgniter 2 problem with routing - El Forum - 06-15-2012 [eluser]Riley123[/eluser] I have this in my routing and it works. $route['page/(:any)'] = 'page/load/$1'; but when i use the i18n library it doesn't the library tells me to add this to routes: $route['^fr/(.+)$'] = "$1"; $route['^en/(.+)$'] = "$1"; // '/en' and '/fr' URIs -> use default controller $route['^fr$'] = $route['default_controller']; $route['^en$'] = $route['default_controller']; which then screws up my page/any route. I tried $route['(en|fr)/page/(:any)'] in my route and no success. Anyone know what I'm doing wrong? I'm not a regex expert. |