iSeries home   |   Easy400     |   CGIDEV2  
Public-Source
 
Introduction
 
Download
 
 

 
XLT941  
HTML translator for CGIDEV2 CGI programs


  This utility was originally developed by Giovanni B. Perotti (Italy) for an iSeries customer needing to quickly translate a number of WEB applications to several languages. After successfully fulfilling his needs, this customer agreed to have the utility made available to others sharing the same need.


While many companies have successfully implemented Internet and Intranet WEB application on IBM iSeries through the easy-to-learn&use CGIDEV2 technique, some of them may be needing some quick facility to translate their HTML presentations into other national languages.
This seems be driven by emerging opportunities in foreign countries, both for manufacturing and for marketing reasons.

Translating HTML scripts to another national language is not an easy job. First of all, it takes some relevant skill in HTML and Javascript. Even so, technical people doing translation may incidentaly incur trivial mistakes (such a wrong keystroke) that would damage the functionality of some script. In other words, that is a tedious and difficult job, prone to human errors, requires skilled personnel, is slow and expensive.

This is why one may find several HTML translators, usually running on PC's. These tools do not require any specific technical skill to perform the translation. However, they may not come out as perfect when dealing with HTML scripts developed for use of CGIDEV2 based programs, because of

  • specific section headers required by CGIDEV2
  • the special way the output variables are coded for CGIDEV2

This is why we suggest to try XLT941, a public source tool, suited for translating CGIDEV2-based HTML scripts.
Free download is available from the Easy400 site.

XLT941 supports HTML translation to any SCS national language. Double byte (DBCS)languages are not supported.

Operation highlights

  • all the translation activity is driven from a client browser and takes place on the HTTP server
  • the subjects of translation are HTML stream files residing on the HTTP server IFS
  • access to the server is validated through existing user profiles
  • concurrent translation activities can take place from several clients

Translator features

  • initial parameters are used to provide:
    • the names of the source (the one to be translated) and the target (the translated) stream files
    • the CGIDEV2 section name left delimiter (e.g. "<as400>")
    • an up-to-three character optional prefix to be added to the translated section names (thus allowing a CGI program to load multiple language stream files)
    • whether complex textx strings (including style HTML tags) should be
      • prompted as a whole for translation (this requires some minimum HTML skill), or
      • prompted for translation through several segments (thus requiring no HTML skill, but translation could become rather cumbersome)
    • choices of the source and the target languages (this has to do with the XLT914 internal translation dictionaries, see later)
  • the browser screen is divided in three frames
    • the left frame displays the HTML script to be translated
    • the right frame displays the HTML script after translation
    • the middle frame is used by the operator to control translation
  • about translation
    • only text strings are subject to translation, the rest of the HTML/javascript code is copied without any operator's intervention
    • text strings eligible for translation may come from:
      • obvious texts, such as from text paragraphs or other
      • javascript alerts
      • button texts originated from
        • <input type=submit ...>
        • <input type=button ...>
      • "alt" or "title" parameters within HTML tags
        • <img ...>
        • <a href= ...>
        • <input type=image ...>
    • texts strings to be translated can be easily copied into the translation bed, thus easing in some cases the keying work
    • any time a translation for the same text was already recorded, it is diplayed as a default in the translation bed
    • Translated text are saved into an internal translation dictionary organized by user profile, source language, target language, source text string
  • advanced automation
    • a translation can be stopped at any time and resumed through a built-in checkpoint
    • a "cruise" feature allows a translation to go on by itself, until a non-translated text is met

Maintenance of translated HTML stream files

When you need to update a master (e.g. in English language) HTML/Javascript stream file, you will of course have to update also the translated stream files (e.g. in French, German, Italian and Spanish languages).
The question is about this added cost of translation maintenance.
The maintenance cost for redoing all the translations is very minimum. This is just another great advantage of using XLT941. This is because
  • All the previous translations are saved in a dictionary database file (XLT941DATA/XLTDCT) records with the following layout
    • User profile name
    • name of the master stream file
    • national language of the master stream file
    • national language of the translated stream file
    • Text string to be translated
    • Translated text string
  • Therefore, already translated text strings are automatically applied during a subsequent translation and translation is required only for new text strings.
  • HTML, CSS and Javascript code are transparent to a translation: when just some code has been changed, a re-translation cost is just a matter of a few seconds.
In other words, translation maintenance cost is something you should never be concerned for when XLT941 is your translation tool.

Importing and exporting translation dictionary entries

The translation dictionary database file (XLT941DATA/XLTDCT) size may increase very rapidly during translations.
It is therefore recommended, when a full translation of a given application is complete, to remove its translation dictionary entries from the dictionary database file.
This can easily be done through command XLT941/DCTEXP (Export dictionary entries). This command allows to copy a set of dictionary entries to a smaller IFS stream file (so that you may for instance store it on a PC). Optionally these entries may be also removed from the online dictionary.
Should you later one need to bring back those entries to the online dictionary for some application maintenance, you can easily do it with command XLY941/DCTIMP (Import dictionary entries).

Requirements

  • V5R2 as a minimum
  • ILE-RPG compiler (just used during the installation of the utility)
  • HTTP server
  • HTTP instance directives provided within XLT941 must be installed
  • CGIDEV2 installation not needed (CGIDEV2 service program provided within library XLT941)
  • This utility was successfully tested on the following WEB browsers: Firefox, Internet Explorer, Microsoft Edge, Chrome, Opera, Sarari.

XLT941 screens
XLT941 is designed to support several presentation languages: the desired presentation language can be chosen from a selection list, and changed at any time. Two presentation languages are currently available: US English and Italian.
Translating XLT941 screens to another language (French, German, Spanish, etc.) is a rather quick and easy job, as XLT941 can be used for this.
Should anyone volunteer for a translation to another national language, please get in touch with the author.


    Contact