CodeIgniter Forums
What is the common way to implement multi-language website? - 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: What is the common way to implement multi-language website? (/showthread.php?tid=12190)



What is the common way to implement multi-language website? - El Forum - 10-09-2008

[eluser]x386[/eluser]
And now! I'm going to create a multi-language website. How should I do this? I mean, I should use url parameter something like ?lang=en or maybe mysite.com/lang/controller/... or... how you implement a multi language website?


What is the common way to implement multi-language website? - El Forum - 10-09-2008

[eluser]Mirage[/eluser]
I prepare my multi language by making the 'lang' identifier the first URI segment and routing accordingly. That provides me with a consistent workable solution.

Prettier is when you can use cookies to store the language selection. But there's always a chance that might not work due to browser conditions. Another way is using cookies which may or may not work depending on the audience. So I use this option as my preferred way but if cookies are off, I then fall back on urls. Ergo - you definitely want to have that working first and foremost.

Cheerio,
-m


What is the common way to implement multi-language website? - El Forum - 01-13-2009

[eluser]Roland B.[/eluser]
[quote author="x386" date="1223600486"]And now! I'm going to create a multi-language website. How should I do this? I mean, I should use url parameter something like ?lang=en or maybe mysite.com/lang/controller/... or... how you implement a multi language website?[/quote]

There is a new Language Selection 2 that uses both a cookie and an automatically appended URI segment for language detection and propagation between pages.


What is the common way to implement multi-language website? - El Forum - 01-14-2009

[eluser]Unknown[/eluser]
Or use subdomains, which I'd say would make the url "look" much better


What is the common way to implement multi-language website? - El Forum - 01-14-2009

[eluser]GSV Sleeper Service[/eluser]
We've used a pre-system hook that looks at the domain name and determines the language to use from that. yes, it would have been easier to use sub domains or even domain.com/en , domain.com/fr etc, but the touchy-feely folks in marketing decided that each country had to have its own domain.

The Upper Class way to implement a multi-language website is to get your butler to do it.


What is the common way to implement multi-language website? - El Forum - 01-16-2009

[eluser]Référencement Google[/eluser]
GSV Sleeper Service, would you mind to post your hook code here?