gettext_localize.rb

Path: vendor/plugins/gettext_localize/lib/gettext_localize.rb
Last Update: Thu May 03 11:47:19 +0200 2007

general gettext definition functions. order in wich GettextLocalize tries to load options

locale:

  - cookie set with name 'lang'
  - locale set in controller with set_locale(lang)
  - locale set in environment with GettextLocalize::default_locale = lang
  - locale set in environment variable $LANG
  - locale set in this plugin init.rb with GettextLocalize::fallback_locale = lang

country

  - cookie set with name 'country'
  - country set in controller with set_country(country)
  - country set in environment with GettextLocalize::default_country = country
  - country part of locale
  - country set in this plugins init.rb with GettextLocalize::fallback_country = country

textdomain:

  - textdomain set in plugin using plugin_bindtextdomain(textdomain)
    uses loadpath RAILS_ROOT/vendor/plugins/$plugin/locale
  - textdomain set in controller with init_gettext(textdomain)
    uses loadpath RAILS_ROOT/locale
  - textdomain set in environment.rb with GettextLocalize::default_textdomain = textdomain
  - app_name set in environment.rb with GettextLocalize::app_name = app
  - name of the directory the rails app is in

Required files

gettext  

[Validate]