Shalafister's
Shalafister's

Reputation: 889

Rails - Database Translation static values

I have a model called house. In this model I have some amenities such as Wi-fi, Tv, air conditioning etc. These are basically in english and checkbox. User clicks them and I show them on home#show page with disabled class as; <%= @home.amenities.each do |amenity| %> ....

The thing is users can select language with locale variable so that the web site turns in to french for instance. For the static texts, flash and error messages I was able translate and works just fine.

But I do not know how should I translate these model based values. The website looks like frenglish right now.

Upvotes: 0

Views: 137

Answers (1)

Paul Fioravanti
Paul Fioravanti

Reputation: 16793

For internationalisation/translations of database data in Rails, I'd highly recommend using the Globalize gem.

Upvotes: 1

Related Questions