dhis2-devs team mailing list archive
-
dhis2-devs team
-
Mailing list archive
-
Message #28496
Text Translation
Hi Everyone,
The challenge I have:
I would like to harness DHIS2's language translation engine to translate some text on my DHIS2 database login page.
The scenario:
Attached to this mail is a screenshot of my database login page. I have some text (in French) in the footer area of the page that reads, "Realiser un monde ou chaque grossesse est desiree...chaque accouchement sans danger...et le potentiel de chaque jeune accompli" and sitting just next door to the left of my text is the all-powerful language selection box where one selects the login page language. So I thought I should be able to use this wonderful translator to translate my text to whatever language the user selects. So, for example if a user selects English, the text translates into the English equivalent which reads "Delivering a world where every pregnancy is wanted...every childbirth is safe...and every young person's potential is fulfilled"
I placed the text on the login page using the code:
<span id="unfpaMandateArea" style="margin-left: 140px">Realiser un monde ou chaque grossesse est desiree...chaque accouchement sans danger...et le potentiel de chaque jeune accompli</span>
as shown in the attached text file.
The Help I seek:
Please how can I tweak the login page language selector code snippet shown here, (or any other code in DHIS2) to do exactly what I need:
<select id="localeSelect" onchange="login.localeChanged()" style="margin-left: 30px">
<option value="">[ Change language ]</option>
#foreach( $locale in $availableLocales )
<option value="${locale.language}">${locale.displayName}</option>
#end
</select>
I currently use:
DHIS 2 version 2.14
Build revision: 13726
Build date: 2014-01-20 21:20
Your kind assistance would be highly appreciated.
John
John Ojo MD, FMCPH
Accra, Ghana.
Mobile: +233 234691626
Skype: Johnojo
Email: jnojo@xxxxxxxxx
Attachment:
login_page.png
Description: PNG image
<select id="localeSelect" onchange="login.localeChanged()" style="margin-left: 30px">
<option value="">[ Change language ]</option>
#foreach( $locale in $availableLocales )
<option value="${locale.language}">${locale.displayName}</option>
#end
</select>
<span id="unfpaMandateArea" style="margin-left: 140px">Realiser un monde ou chaque grossesse est desiree...chaque accouchement sans danger...et le potentiel de chaque jeune accompli</span>