• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Is it possible to specify the initial language?

 
Ranch Hand
Posts: 17424
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Before the users get registered and can specify their language preference, is it possible to specify the default language of the application? Something like

http://kheops-tech.com/jforum/forums/list.page?lang=fr


Thanks.

J-R
[originally posted on jforum.net by Anonymous]
 
Migrated From Jforum.net
Ranch Hand
Posts: 17424
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Yes.

Open the file WEB-INF/config/SystemGlobals.properties and change the value of the key i18n.default to the desired language. Just dont change the value of i18n.default.admin, which should remain to "en_US".

Rafael
[originally posted on jforum.net by Rafael Steil]
 
Migrated From Jforum.net
Ranch Hand
Posts: 17424
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Well,

I meant a different language depending on an externeral condition. For exemple, I would like our French customers browsing the French version of our web site to see JForum in French by default. Our english customers would be sent to JForum in English. That's why I thought that passing a parameter in the URL could be one flexible way of doing it.

Thanks,

J-R
[originally posted on jforum.net by Anonymous]
 
Migrated From Jforum.net
Ranch Hand
Posts: 17424
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hm, right.

Well, currently it's not possible. I created a new request feature:

http://www.jforum.net/jira/browse/JF-148

Rafael
[originally posted on jforum.net by Rafael Steil]
 
Migrated From Jforum.net
Ranch Hand
Posts: 17424
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Done. This feature is added to the CVS. To use it, pass the parameter "lang" in the URL using a valid language name - any in WEB-INF/config/languages/locales.properties.

In order to have this functionality working correcly, you should not use "Friendly URLs". Example:



There is no need to persist the language through other pages, it is done internally by jforum. Also, it is only possible to change the language using request parameter for Anoymous users and in the forum listing page.

Rafael
[originally posted on jforum.net by Rafael Steil]
 
Migrated From Jforum.net
Ranch Hand
Posts: 17424
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
That is fast.

Tank you!

J-R
[originally posted on jforum.net by Anonymous]
reply
    Bookmark Topic Watch Topic
  • New Topic