internationalization module

Discussion in 'Perl Misc' started by chatiman, Mar 2, 2004.

  1. chatiman

    chatiman Guest

    Hello,

    I'm searching a module to translate my scripts into different languages.
    Idealy this module will have the following features :
    - Easy to use and install (part of the standard perl packages idealy)
    - Can translate text with perl variables
    eg: "Word $word"
    - Would take a text identifier and returns the translated version with
    variables
    evaluated

    Does this exists or do I have to write it ?


    Thanks
     
    chatiman, Mar 2, 2004
    #1
    1. Advertising

  2. chatiman

    Anno Siegel Guest

    chatiman <> wrote in comp.lang.perl.misc:
    > Hello,
    >
    > I'm searching a module to translate my scripts into different languages.
    > Idealy this module will have the following features :
    > - Easy to use and install (part of the standard perl packages idealy)
    > - Can translate text with perl variables
    > eg: "Word $word"
    > - Would take a text identifier and returns the translated version with
    > variables
    > evaluated
    >
    > Does this exists or do I have to write it ?


    Write it!

    Anno
     
    Anno Siegel, Mar 2, 2004
    #2
    1. Advertising

  3. chatiman

    chatiman Guest

    "Anno Siegel" <-berlin.de> a écrit dans le message de
    news: c229lp$mi0$-Berlin.DE...
    > Write it!
    >

    Can "gettext" do that (variable evaluation) ?

    > Anno
     
    chatiman, Mar 2, 2004
    #3
  4. chatiman

    Anno Siegel Guest

    chatiman <> wrote in comp.lang.perl.misc:
    >
    > "Anno Siegel" <-berlin.de> a écrit dans le message de
    > news: c229lp$mi0$-Berlin.DE...
    > > Write it!
    > >

    > Can "gettext" do that (variable evaluation) ?


    What is "gettext"? What is "variable evaluation"?

    You haven't made very clear yet what you actually want to do.

    Anno
     
    Anno Siegel, Mar 2, 2004
    #4
  5. chatiman

    Ben Morrow Guest

    -berlin.de (Anno Siegel) wrote:
    > chatiman <> wrote in comp.lang.perl.misc:
    > >
    > > "Anno Siegel" <-berlin.de> a écrit dans le message de
    > > news: c229lp$mi0$-Berlin.DE...
    > > > Write it!
    > > >

    > > Can "gettext" do that (variable evaluation) ?

    >
    > What is "gettext"?


    'gettext' is a standard i18n/l10n library.

    > You haven't made very clear yet what you actually want to do.


    I think he wants to localise his app... to the OP: look at
    Locale::Maketext.

    Ben

    --
    don't get my sympathy hanging out the 15th floor. you've changed the locks 3
    times, he still comes reeling though the door, and soon he'll get to you, teach
    you how to get to purest hell. you do it to yourself and that's what really
    hurts is you do it to yourself just you, you and noone else **
     
    Ben Morrow, Mar 2, 2004
    #5
  6. chatiman wrote:
    > I'm searching a module to translate my scripts into different
    > languages. Idealy this module will have the following features :
    > - Easy to use and install (part of the standard perl packages
    > idealy)
    > - Can translate text with perl variables
    > eg: "Word $word"
    > - Would take a text identifier and returns the translated
    > version with variables evaluated
    >
    > Does this exists or do I have to write it ?


    I'm sure there are quite a few tools to help you with
    internationalization, so you don't need to re-invent that wheel.
    Personally I'm applying a GNU gettext approach for i18n of a Perl
    program, and I'm quite happy with it.

    As you may know, the gettext language files consist of both the
    English text strings and the strings of respective language, and I'm
    creating those without Perl, i.e. using the GNU gettext program.

    To incorporate them into my program I'm using this simple CPAN module:
    http://search.cpan.org/perldoc?Locale::PGetText

    By help of that module, DBM files are created out from the language
    files. There is also a gettext() function (of course), and all the
    output strings in the program are passed to that function, which picks
    the strings from the selected DBM database.

    --
    Gunnar Hjalmarsson
    Email: http://www.gunnar.cc/cgi-bin/contact.pl
     
    Gunnar Hjalmarsson, Mar 2, 2004
    #6
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Pablo Jose Almeida da Guia

    Internationalization Problem

    Pablo Jose Almeida da Guia, Dec 5, 2003, in forum: ASP .Net
    Replies:
    0
    Views:
    376
    Pablo Jose Almeida da Guia
    Dec 5, 2003
  2. Natty Gur

    Re: internationalization problem

    Natty Gur, Dec 23, 2003, in forum: ASP .Net
    Replies:
    1
    Views:
    414
    Francois Malgreve
    Dec 23, 2003
  3. Francois Malgreve

    internationalization problem continues.

    Francois Malgreve, Dec 29, 2003, in forum: ASP .Net
    Replies:
    0
    Views:
    315
    Francois Malgreve
    Dec 29, 2003
  4. =?Utf-8?B?UGl5dXNoIEdvdmls?=

    internationalization of Apps ????

    =?Utf-8?B?UGl5dXNoIEdvdmls?=, Jun 2, 2004, in forum: ASP .Net
    Replies:
    0
    Views:
    359
    =?Utf-8?B?UGl5dXNoIEdvdmls?=
    Jun 2, 2004
  5. Jules
    Replies:
    3
    Views:
    498
Loading...

Share This Page