Welcome Guest, Not a member yet? Register   Sign In
Problem with route and URI Language code
#2

[eluser]KeyStroke[/eluser]
Here's how I did it in my application:
Code:
$route['(en|ar|de|nl|es|fr|ru|pt)*/*(.*)'] = '$2';
I have valid language codes in my regex as you can see. This will route (for example) this:
http://example.com/ar/controller

to this:
http://example.com/controller

And you can still access the controller directly without problems.

Hope this helps.


Messages In This Thread
Problem with route and URI Language code - by El Forum - 04-21-2008, 03:48 AM
Problem with route and URI Language code - by El Forum - 04-21-2008, 04:25 AM
Problem with route and URI Language code - by El Forum - 04-21-2008, 04:59 AM



Theme © iAndrew 2016 - Forum software by © MyBB