VIVO Documentation
...
Languages can be selected in a variety of ways, depending on the installation parameters:
VIVO language files are available for English (U.S. and Canadian), Spanish, Brazilian Portuguese, French (Canadian) and German. If you need support for another language, please inquire of the VIVO mailing lists, to see if another group has the files you need.
...
vivo_home_dir/config/runtime.properties
file in your VIVO home directory:RDFService.languageFilter = true
languages.selectableLocales = en_US, de_DE
For more details, see How to Enable Languages in VIVO as an Administrator.
<version>
in the pom.xml
files for VIVO and Vitro-languages matches the <version>
of VIVO you are building against. You may need to change the version in multiple places in the files.VIVO-language
and Vitro-language) and install them with Maven using mvn install
mvn install -o -s installer/my-settings.xml
(Note the -o flag, this forces maven Maven to use the language projects from your local repository instead of downloading from a remote repository)
vivo_home_dir/config/runtime.properties
file in your VIVO home directory:RDFService.languageFilter = true
languages.selectableLocales = en_US, de_DE
...
Your locale is an internationally recognized code that specifies the language you choose, and the region where it is spoken. For example, the locale string fr_CA
is used for French as spoken in Canada, and es_MX
is used for Spanish as spoken in Mexico. Recognized codes for languages and regions can be found by a simple Google search. Here is a list of locales that are recognized by the Java programming language. You may also use this definitive list of languages and regions, maintained by the Internet Assigned Numbers Authority.
...
You can get the US English (en_US) files from the VIVO-language and Vitro-language among the vivo-project repositories (https://github.com/vivo-project), to use as a template for your own files.
The process simply consist consists of duplicating each file having the extension en_US inside VIVO/Vitro -language repositories and renaming the copy using the locale of the new language. The new file files will reside along side ( in the same a directory ) the original one. named after the new locale.
For example, when initializing the languages files for Estonian (et_EE)
, copying the file vivo_all_en_US.properties will help creating vivo_all_et_EE.properties. Both of them The new file will reside in vivo-languages/et_EE/webapp/src/main/webapp/i18n
...
...
They are located in:
...
Code Block | ||
---|---|---|
| ||
Vitro-languages/et_EE/webapp/src/main/webapp/templates/freemarker/search-help_et_EE.ftl Vitro-languages/et_EE/webapp/src/main/webapp/templates/freemarker/termsOfUse_et_EE.ftl Vitro-languages/et_EE/webapp/src/main/webapp/templates/freemarker/userAccounts-acctCreatedEmail_et_EE.ftl Vitro-languages/et_EE/webapp/src/main/webapp/templates/freemarker/userAccounts-acctCreatedExternalOnlyEmail_et_EE.ftl Vitro-languages/et_EE/webapp/src/main/webapp/templates/freemarker/userAccounts-confirmEmailChangedEmail_et_EE.ftl Vitro-languages/et_EE/webapp/src/main/webapp/templates/freemarker/userAccounts-firstTimeExternalEmail_et_EE.ftl Vitro-languages/et_EE/webapp/src/main/webapp/templates/freemarker/userAccounts-passwordCreatedEmail_et_EE.ftl Vitro-languages/et_EE/webapp/src/main/webapp/templates/freemarker/userAccounts-passwordResetCompleteEmail_et_EE.ftl Vitro-languages/et_EE/webapp/src/main/webapp/templates/freemarker/userAccounts-passwordResetPendingEmail_et_EE.ftl VIVO-languages/et_EE/webapp/src/main/webapp/templates/freemarker/body/aboutMapOfScience_et_EE.ftl VIVO-languages/et_EE/webapp/src/main/webapp/templates/freemarker/body/aboutQrCodes_et_EE.ftl VIVO-languages/et_EE/webapp/src/main/webapp/templates/freemarker/visualization/mapOfScience/mapOfScienceTooltips_et_EE.ftl |
...
Data in the RDF models includes include labels for the properties and classes, labels for property groups and class groups, labels for menu pages and more. Here is the list of directories where one will have to create required rdf files:
In each case, the delivered file in English has a corresponding file with the same name followed by and underscore and the name of the locale. See illustrations below:
Code Block | ||
---|---|---|
| ||
[VIVO]/languages/et_EE/rdf/applicationMetadata/firsttimei18n/et_EE/applicationMetadata/firsttime/classgroups_labels_et_EE.n3 [VIVO]/languages/et_EE/rdf/i18n/et_EE/applicationMetadata/firsttime/propertygroups_labels_et_EE.n3 [VIVO]/languages/et_EE/rdf/i18n/et_EE/display/everytime/PropertyConfig_et_EE.n3 [VIVO]/languages/et_EE/rdf/i18n/et_EE/display/firsttime/aboutPage_et_EE.n3 [VIVO]/languages/et_EE/rdf/i18n/et_EE/display/firsttime/menu_et_EE.n3 [VIVO]/languages/et_EE/rdf/i18n/et_EE/tbox/firsttime/vitroAnnotations_et_EE.n3 |
...
Code Block | ||
---|---|---|
| ||
<http://vivoweb.org/ontology#vitroClassGrouppeople> <http://www.w3.org/2000/01/rdf-schema#label> "inimesed"@et-EE . <http://vivoweb.org/ontology#vitroClassGrouppublications> <http://www.w3.org/2000/01/rdf-schema#label> "teadus"@et-EE . <http://vivoweb.org/ontology#vitroClassGrouporganizations> <http://www.w3.org/2000/01/rdf-schema#label> "organisatsioonid"@et-EE . <http://vivoweb.org/ontology#vitroClassGroupactivities> <http://www.w3.org/2000/01/rdf-schema#label> "tegevused"@et-EE . |
If you allow the user to select a preferred language, you must supply an image for the user to click on. Typically, this image is of the flag of the country(or the language) where the language is spoken.
Here are the locations you need to add the flag of the language:
You need to add the image to the themes you will be using. Here the path to the image that will load with wilma:
Code Block | ||
---|---|---|
| ||
VIVO-languages/webapp/src/main/webapp/themes/wilma/i18n/images/select_locale_et_EE.gif |
Panel | ||
---|---|---|
| ||
...