Search code examples
ruby-on-railsrubyruby-on-rails-3refinerycms

rails t function showing i18n


I'm working on my first refinerycms project and there is this line in the footer:

<%= t('.copyright', :year => Time.now.year, :site_name => Refinery::Core.site_name) %>

It's displaying this on my site:

i18n: Copyright

Where does the i18n come from and is the t function needed?

EDIT:

My /config/locales/en.yml contains the code below. Do i need to add something to this or would it best just to remove the t() tag?

en:
  hello: "Hello world"

Solution

  • i18n it's the internationalization library that comes with Rails, wich helps for having translation for diferent locations in your Rails app.

    t() it's just the call for translate, I think it's an alias actually.

    You should have a yaml file in your locales folder where there is a copyright, wich needs a year and a site_name.

    I guess you changed the location so there is no translation, since refineryCms should be english only.