Hi
I have a problem with gettext. I did some eays steps from a forum wihout
any problems:
Replace Strings with _(‘balbalbal’)
build po file with rake-task /po/de_DE/domain.po
Edit this file
build mo file with rake-task /locale/de_DE/LC_MESSAGES/domain.mo
insert “require ‘gettext/rails’” and “init_gettext ‘domain’” to
applicationController
If I start my application it works without any error-message but the
Strings are not replaced with strings from the domian.mo file. If I
check GetText.local it is “de_DE”! So why does it not work?
I also fount out this: If I remove “require ‘gettext/rails’” from
ApplicationController the init_gettext method already works without
errors. I don’t know why.
What do you mean by "f I remove “require ‘gettext/rails’” from
ApplicationController the init_gettext method already works without
errors."? Does this mean you have already made it working?
With no errors I mean no exceptions in error log!
So the solution was very easy: I switched from Rails 1.2.3 to 2.0.2!
Thats all! I worked with a tutorial which based on 1.2.3. In this
tutorial was also a descrition of gettext, but without any comment about
the version of gettext. I think the latest Version of gettext does not
work with some old rails version.
I am using Rails 2.0.2 and Ruby 1.8.6. Both are the newest versions.
Only validation error messages in models are displayed based on
locale.
This seems OS package dependent, since we do not have the problem with
Ubuntu but only for RH Linux.