Personal tools

OpenEMR Internationalization Configuration

From OpenEMR Project Wiki

(Difference between revisions)
Jump to: navigation, search
(Language Translations Setting)
Line 8: Line 8:
== Multi Language Tool. ==
== Multi Language Tool. ==
-
This is the Language Administration page in OpenEMR (Adminstration->Language). This is where you can customize languages and language definitions. You can add new languages,
+
This is the Language Administration page in OpenEMR (Administration->Language). This is where you can customize languages and language definitions. You can add new languages,
-
,add new English Constants, and modify/add language definitions. (Please note
+
,add new English Constants, and modify/add language definitions. ([[[[OpenEMR Internationalization Development|Please note
you can also enter your translations into the official OpenEMR Language
you can also enter your translations into the official OpenEMR Language
-
Translation GoogleDoc spreadsheet; see section II. for details)
+
Translation GoogleDoc spreadsheet]])
-
  The following is an explanation of the options in this tool:
+
The following is an explanation of the options in this tool:
-
    Add Language: You get a box to enter a new language.
+
===Add Language===
-
    Add Constant: You get a box to add a new string to be used in the translation
+
:You get a box to enter a new language.
-
                  function, this one should be used only if you know what you are
+
===Add Constant===
-
                  doing, mostly, if you added some custom programming with new
+
:You get a box to add a new string to be used in the translation function, this one should be used only if you know what you are doing, mostly, if you added some custom programming with new text output. The "constant" string can be literally what you want to say or a shorter reference to it.
-
                  text output. The "constant" string can be literally what you
+
===Edit Definitions===
-
                  want to say or a shorter reference to it.
+
English is used as the reference language, if you click the English label you'll get a set of all constants and the English definitions at the side. If no definition is loaded yet for a given constant then a blank box is shown, by entering a definition and clicking "Load Definition" you save whatever changes you made. If you click other label than English, you get a set of all constants, the English definition at the side, and an input box to enter/modify the definition in the selected language.
-
    Edit Definitions: English is used as the reference language, if you click
+
===Manage Translations===
-
                      the English label you'll get a set of all constants and
+
This tool allows you to re-synchronize your local language modifications after importing an official released set of OpenEMR translations.
-
                      the English definitions at the side. If no definition is
+
-
                      loaded yet for a given constant then a blank box is shown,
+
-
                      by entering a definition and clicking "Load Definition"  
+
-
                      you save whatever changes you made. If you click other
+
-
                      label than English, you get a set of all constants,
+
-
                      the English definition at the side, and an input box
+
-
                      to enter/modify the definition in the selected language.
+
-
    Manage Translations: This tool allows you to re-synchronize your
+
-
                        local language modifications after importing
+
-
                        an official released set of OpenEMR translations.
+
== Official OpenEMR Language Translations ==
== Official OpenEMR Language Translations ==
Line 55: Line 45:
[[Administration_Globals#Locale|Administration Globals]] for more details.
[[Administration_Globals#Locale|Administration Globals]] for more details.
-
== Developer Instructions ==
 
-
 
-
The translation is done by the xl() custom function, which can be found
 
-
at openemr/library/translation.inc.php.
 
-
Its semantics are very simple.
 
-
 
-
<pre>xl(string)</pre>
 
-
 
-
Which with examples means:
 
-
 
-
<pre>xl('translate this')</pre>
 
-
 
-
By default the function will return the translation.
 
-
 
-
First it uses the LANGUAGE constant defined to pick the translation.
 
-
 
-
Second it goes for the translation, if none is found, then the same string entered is used and returned as is.
 
-
 
-
Another example of use includes:
 
-
 
-
<pre>echo ("this and " . xl('translate this') . " that too");</pre>
 
-
 
-
Further details and rules on use can be found on the wiki here:
 
-
[[Development_Policies#Internationalization|Development Policies - Internationalization]]
 
-
 
-
There are also wrappers to the xl() function that are used infrequently in specific situations. Please
 
-
refer to openemr/library/translation.inc.php for more details.
 
[[Category:Internationalization]][[Category:Configuration Guide]]
[[Category:Internationalization]][[Category:Configuration Guide]]

Revision as of 23:19, 6 November 2011

NOTE THAT IF YOU ARE INTERESTING IN HELPING WITH TRANSLATIONS, PLEASE CLICK HERE FOR MORE INFORMATION


Contents


OpenEMR Internationalization Documentation

Multi Language Tool.

This is the Language Administration page in OpenEMR (Administration->Language). This is where you can customize languages and language definitions. You can add new languages, ,add new English Constants, and modify/add language definitions. ([[Please note you can also enter your translations into the official OpenEMR Language Translation GoogleDoc spreadsheet)

The following is an explanation of the options in this tool:

Add Language

You get a box to enter a new language.

Add Constant

You get a box to add a new string to be used in the translation function, this one should be used only if you know what you are doing, mostly, if you added some custom programming with new text output. The "constant" string can be literally what you want to say or a shorter reference to it.

Edit Definitions

English is used as the reference language, if you click the English label you'll get a set of all constants and the English definitions at the side. If no definition is loaded yet for a given constant then a blank box is shown, by entering a definition and clicking "Load Definition" you save whatever changes you made. If you click other label than English, you get a set of all constants, the English definition at the side, and an input box to enter/modify the definition in the selected language.

Manage Translations

This tool allows you to re-synchronize your local language modifications after importing an official released set of OpenEMR translations.

Official OpenEMR Language Translations

The OpenEMR language translations are built from a collaborative Google Doc. If you would like to add a language or help with a current language, please contact us. You could then enter your translations into this spreadsheet, which will then become a permanent part of OpenEMR. This process has become very streamlined with a fast turnaround time, so we would suggest you enter data on this collaborative spreadsheet rather than entering into your local OpenEMR installation only. Note that the translations sets are built daily. To download the most uptodate set of translations, go HERE.

Language Translations Setting

These are configured in Administration->Globals->Locale. Mainly, you can configure the default language and what is displayed in the login language selection menu (you can also disable this menu). There are also more advanced setting to turn off certain parts of the translation engine. Please see the Locale section of Administration Globals for more details.