Open dfguo opened 9 years ago
It's not forced; you can turn if off by doing this in config/application.rb
:
config.gettext_i18n_rails.use_for_active_record_attributes = false
This could definitely be documented better, though ... It took me a trip to the source code to figure this out :-)
nice! Thanks!
Is there a way to do the reverse -- that is, use Gettext for the error message? I'd like to use Gettext for as much of my i18n as possible.
Ah, answering my own question, I see I can put the dot.key.path
as a key into the PO file. Not great, but functional.
I have a related question:
Error messages can be translated through FastGettext, if the ':message' is a translation-id.
Could you help explain how this is done? Thanks
The model attribute is translated using gettext while the error message is translated using i18n. Is there any reason why the attributes can't be translated using i18n?