Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: XMLUI where to edit section

...

The interface will automatically determine which file to select based upon the user's browser and system configuration. For example, if the user's browser is set to Australian English then first the system will check if messages_en_au.xml is available. If this translation is not available it will fall back to messages_en.xml, and finally if that is not available, messages.xml.

DSpace XMLUI supplies an English only translation of the interface, which can be found in the XMLUI web application ([dspace]/webapps/xmlui/i18n/messages.xml), after you first build DSpace.

If you wish to add other translations to the system, or make customizations to the existing messages.xml file, you can place them in the following directory:

Where to edit

In some cases you may want to add additional keys to the message catalog or changing the particular wording of DSpace concepts. For example, you may want to change "Communities" into "Departments". These kind of changes may get automatically overwritten again when you upgrade to the newest version of DSpace. It is therefore advised to keep such changes isolated in the following location:

code
Code Block
titleRecommended location for i18n customizations
[dspace-source]/dspace/modules/xmlui/src/main/webapp/i18n/

After rebuilding DSpace, any messages files placed in this directory will be automatically included in the XMLUI web application. Files of the same name will override any default files. By default, this full directory path may not exist or may be empty. If it does not exist, you can simply create it. You can place any number of translation catalogues in this directory. To add additional translations, just add another copy of the messages.xml file translated into the specific language and country variant you need

After building and deploying, DSpace will finally read the files from the following location:

Code Block
titleLocation where your i18n files are being deployed
[dspace]/webapps/xmlui/i18n/messages.xml

Again, note that you will need to rebuild DSpace for these changes to take effect in your installed XMLUI web application!

Warning
titleDo not customize your messages in the webapps directory

While it seems like a fast option to change your messages straight in the deployed dspace directory, these changes are very volatile. If you rebuild and redeploy DSpace, these changes will get lost.

For more information about the [dspace-source]/dspace/modules/ directory, and how it may be used to "overlay" (or customize) the default XMLUI interface, classes and files, please see: Advanced Customisation

...