seanpor has asked for the wisdom of the Perl Monks concerning the following question:

We are looking to write a mod_perl web site with login, and some personalization, along with other transactional bits and pieces. The site (or sites) will probably get quite a bit of interest. I see of the order of maybe 15-20 web pages with about 10 small-ish ".cgi" scripts which will each return some feedback.

The hard bit is that we want to do all this in english, a couple of european languages, japanese, chinese, thai, and possibly arabic (right to left languages)...

PageKit looks like it might be a possible option. Do monks know of others - have you used them in Real-Life(tm) ?

Are there any particular strategies that monks recomend? should i put /en/ or /jp/ in the url? etc.

Thanks in advance!

Replies are listed 'Best First'.
Re: mod_perl internationalization
by perrin (Chancellor) on Sep 16, 2002 at 00:00 UTC
    Embperl has support for internationalization, and there is an article about doing it with Template Toolkit here.

      Due to a re-org on the stason.org web site, the above link is broken. Try this page instead and look for the entry in 2001 for the show in Singapore.

      --t. alex
      Life is short: get busy!
Re: mod_perl internationalization
by rob_au (Abbot) on Sep 15, 2002 at 23:56 UTC
    You haven't commented too much on the specifics of how your application interacts with the user or generates HTML pages - Depending upon how much of this has been built within your application, a lot of work could be shifted into template files. This allows for the generation of locale-specific output with a simple change of the output template employed by your script.

    Furthermore, this allows for a clear distinction between code and presentation, such that there is no need to rewrite the code base for each language which your application supports.

    If you are interested in pursuing this development path, I would recommend that you explore the feature-set of the Template Toolkit before re-inventing any wheels.

     

      Thanks Rob! I had intended using some sort of templating system - I'd come across html::template; mason; eperl etc... and a couple of years ago I used a simple templating system based on perl cookbook recipe 20.9. But various web searches hadn't given much in the line of hints as to i18n apart from the obvious "use templates" :-) the app is only in the design stage at the moment - but design needs to finish "real soon now" for budgeting purposes... and something like a templating system can change how the design works... Thanks, Sean
Re: mod_perl internationalization
by Flexx (Pilgrim) on Sep 16, 2002 at 09:36 UTC

    Hi,

    I found Sean M. Burke's Locale::Maketext module to excel in terms of flexibility. It is, however oriented more towards Perl coders than content editors. But I think, especially if you want to support languages of different stems with incompatible grammars (read Locale::Maketext::TPJ13), you'll appreciate this modules flexibility compared to plain gettext and it's derivates.

    So long,
    Flexx