Multilingual Urls

Hello! I’m trying to create multilingual application. I’ve implemented ability of translationable content and next step should be showing it to user. I want to have ability of changing language depending on URL. I’ve found a couple of components for those purposes but they all create urls which I don’t like. For example, my application’s default language is English and I have content which is translated into French. I have page “contacts”, for instance. And URLs which will be generated by application will be:,, but I want to have for default language and for French language. It’s simillar for site’s root too. - for default language and for French.

Is there any methods for implementing these functionality?

provide additional routes that will handle default language routes (without language in URL, but with language provided as default parameter value in route definition).

//route with default language

'<controller:\w+>/<id:\d+>'=>array( '<controller>/view', 'defaultParams'=>array( 'lang'=>'en' ) ),

//route with language




oh, and add ‘matchValue’=>true in CUrlManager configuration so it can select proper routes for any language…