-
Notifications
You must be signed in to change notification settings - Fork 12
Translation Guidelines
Max Mulatz edited this page Mar 1, 2016
·
6 revisions
We are happy, if you help us with internationalization.
For translatating phrases please use the following convention in the view files:
<%= t "application.name_of_my_phrase %>
And in all .yml files add your phrase the key application:
e.g. config/locales/where2help/views/de.yml:
de:
...
application:
name_of_my_phrase: "Übersetzung meiner Phrase"e.g. config/locales/where2help/views/en.yml:
en:
...
application:
name_of_my_phrase: "Translation of my Phrase"To quickly test your language, just temporarily change the default in the :set_locale method in the ApplicationController.
# in /app/controllers/application_controller.rb
def set_locale
# just set it to a symbol of the language you want to test
# e.g. for English:
I18n.locale = :en
end