[cgiapp] Internationalization with Locale::Maketext
jani-hur at jani-hur.net
Thu May 27 08:20:15 EDT 2010
On 05/27/2010 12:45 PM, Jani-Hur wrote:
> I also tried to use $self->localtext_lang, but I got this error:
> Error executing run mode 'test': Can't locate object method "get_handle"
> via package "potest::I18N" (perhaps you forgot to load "potest::I18N"?)
> at /usr/local/share/perl/5.10.1/CGI/Application/Plugin/I18N.pm line 271.
The problem was missing Locale::Maketext::Lexicon module. After the
installation the (CAP::I18N) example started to work as expected.
According to Locale::Maketext::Simple pod it can also work without
Locale::Maketext::Lexicon, but clearly not in this case. I have no idea
why and I'm not going to investigate that (as I think I'm going too far
from my plan).
However now when I reload the test I found these warnings from Apache's
Unrecognized escape \p passed through at (eval 24) line 1.
Unrecognized escape \p passed through at (eval 26) line 1.
Use of uninitialized value $_ in pattern match (m//) at
/usr/share/perl/5.10/I18N/LangTags.pm line 398.
And when I pass the locale value I get these warnings:
Unrecognized escape \p passed through at (eval 25) line 1.
Unrecognized escape \p passed through at (eval 27) line 1.
More information about the cgiapp