ASPX templates
Version 4.x > ASPX templates > Multi-Lingual URL's View modes: 
User avatar
Member
Member
craig.goulding-preactor - 12/18/2009 6:49:01 AM
   
Multi-Lingual URL's
I've already asked this question to Kentico Support, but wanted to know if anyone else has had a similiar requirement and if so how did they solve the problem.

Our website currently supports 14 different languages, and this all seems to be working fine. However we now have another requirement about the url will is displayed.

Currently the site URL is just

http://www.preactor.com/Home.aspx

To change the language, we can add the lang parameter to the query string

http://www.preactor.com/Home.aspx?lang=fr-FR

This all works fine, but we now require the URL to change, so if they are browsing the site in French instead of English, the url looks similiar to

http://www.preactor.com/fr-FR/Home.aspx

Any ideas?

I did find a forum post dating back to 2006 for version 1 saying this isn't supported, things have moved on a bit now, so can anyone give any suggestions on how we could achieve this?

I notice in CMSSiteManager there is a URLPATHPREFIX setting, this is would appear to be the sort of thing we require, but have this set dynamically based on the chosen language.

Thanks in advance for any suggestions.

Craig


User avatar
Member
Member
Alex - 12/22/2009 6:28:52 AM
   
RE:Multi-Lingual URL's
Hello Craig!

You need to use URL Rewrite module in IIS on your site
http://learn.iis.net/page.aspx/461/creating-rewrite-rules-for-the-url-rewrite-module/

You can create rule that replace your
http://www.preactor.com/Home.aspx?lang=fr-FR
to
http://www.preactor.com/fr-FR/Home.aspx
or simply and more convenient
http://www.preactor.com/fr-FR/

User avatar
Member
Member
viktor-avacom - 12/29/2009 4:12:54 AM
   
RE:Multi-Lingual URL's
We have a simple problem. We made a WebSite on croatian language, but now we need to add a english language too. We have red so many articles on devnet.kentico.com/ but we do not understand how we can solve this problem. Can someone explain more detailed part of lang parameters or some another way to solve a problem. And yes, that website has been build on free edition.
Thanks

User avatar
Kentico Support
Kentico Support
kentico_zdenekc - 12/30/2009 7:58:25 AM
   
RE:Multi-Lingual URL's
The Free edition is limited to only one culture for a site, as can be seen at Feature-Matrix edition comparison

The solution that we (Kentico) can offer is a purchase of appropriate paid edition.

Best regards,
Zdenek C.

User avatar
Kentico Support
Kentico Support
kentico_zdenekc - 12/22/2009 7:04:44 AM
   
RE:Multi-Lingual URL's
Hello,

In communication with Craig I've suggested the structure of the content and configuration of URLs (in SiteManager and also CMSDesk) to achieve the scenario with culture prefix. These suggestions can be helpful for everyone and I hope it will be published on our KnowledgeBase soon. (I'll try to post an update here with the link then).

Our language selection webparts (controls) are designed to use the "lang" query property, this can be changed by customization (replacing the language prefix in the current URL with the one you're switching to).

Regards,
Zdenek C.