Beefy Boxes and Bandwidth Generously Provided by pair Networks
Come for the quick hacks, stay for the epiphanies.
 
PerlMonks  

Re: HTML::Template and translations

by jethro (Monsignor)
on Jan 15, 2010 at 12:23 UTC ( [id://817626]=note: print w/replies, xml ) Need Help??


in reply to HTML::Template and translations

localization/internationalization support generally runs unter the name L10N and I18N. Under Linux the gnu library gettext provides functions to translate strings from one language into other languages through a pregenerated database

In perl the library can be accessed through Locale::gettext for example. Another approach would be Locale::Maketext, the reasons for this more programmatic approach are detailed in Locale::Maketext::TPJ13

If you are lucky and have only fixed strings you could pregenerate the templates after any change to the templates, but normally you would have to add the translate step to your templating

PS: There is HTML::Template::Compiled::Plugin::I18N

UDPATE: You migh also want to read http://rassie.org/archives/247 for a critique of the Maketext approach

UPDATE: As dsheroh rightly commented it should be L10N, not I10N

Replies are listed 'Best First'.
Re^2: HTML::Template and translations
by dsheroh (Monsignor) on Jan 16, 2010 at 11:26 UTC
    Just a minor correction: Shouldn't that be "L10N" for "localization"?

    And, since I'm here, I suppose I'll also throw in NLS (National/Native Language Support) and g11n (globalization) as other possible names for it.

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://817626]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others about the Monastery: (5)
As of 2024-03-28 15:18 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found