I have page that translated to en and ru. If user will come to page with other locale, i want that to be used en locale. Is it passible?
Asked
Active
Viewed 1,171 times
3
-
1possible duplicate with: http://stackoverflow.com/questions/2324398/fall-back-to-default-language-if-translation-missing (see second answer) – Baldrick May 09 '12 at 09:12
2 Answers
9
-
1to complete this answer, it should be added in `config/application.rb` – felixyadomi Aug 16 '15 at 15:44
1
You can create a helper method in which you can do the following:
def trans(key)
I18n.t(key, :default => I18n.t(key, :locale => :en))
end

KARASZI István
- 30,900
- 8
- 101
- 128