1 Reply Latest reply: Apr 9, 2010 3:49 AM by 843810 RSS

    Browser language settings

    843810
      Hi,

      In browser I have language settings as follows:

      Czech(cs)
      English(en_us)

      My application does not support Czech and Iam getting labels broken string as lables (??xy.user.name??).

      Can the application load english or default language properties if czech or selected language properties are not available?
      If so what are the changes need to be made from application end.

      Thanks,
      mvrk
        • 1. Re: Browser language settings
          843810
          Hi,

          Java's ResourceBundle provides you a way to fallback to JVM's default locale(i.e. Locale.getDefault()) and load the properties file for the default locale, if it does not find the resource bundle for the specified locale(e.g. Czech). You can make use this API. Please go through the Java API for details.

          Also, for your web application you can design a locale fallback mechanism to determine the locale for a user session (if it is required in your application).
          So that the determined locale is used as a parameter to load resource bundles as well as perform any other locale sensitive operations.

          Hope this helps.

          Regards,
          Rajesh