This article covers a Bloomreach Experience Manager version 11. There's an updated version available that covers our most recent release.

Add internationalization (i18n) to document types

Internationalization of document type string

The Hippo CMS user may login with different languages. You can add translations for document types so the users can see document type names, field captions and field hints in their own language. These translations can be added or changed using the Hippo console.

To add English (en) and Dutch (nl) translations for the document type myhippoproject:mytype, make sure auto-export is turned on, and navigate in the console to the node /hippo:configuration/hippo:translations/hippo:types. This is the location that the CMS uses to load translations for document types. Then add a node of type hipposys:resourcebundles with the name myhippoproject:mytype to hippo:types. Then add two nodes of type hipposys:resourcebundle to myhippoproject:mytype with the names en and nl.

In the resource bundle nodes, you can add the strings that are shown in the UI. To add a translation for the document type string itself, add a property called jcr:name with type String to both the en and nl nodes and give it a value. To add a translation for the field called "title", add a property myhippoproject:title with type String to both the en and nl nodes and give it a value. It is also possible to provide translations for the hints that are shown in the document editor. To add a hint for the title field, add a property myhippoproject:title#hint with type String and give it a value.

By now the console should look something like this:

And the document type editor when logged in using Dutch should look something like this:

If you enable auto-export, it will have exported the following:

{
  "hippo:types": {
    "myhippoproject:mytype": {
      "en": {
        "myhippoproject:title": "Title",
        "myhippoproject:title#hint": "Title hint",
        "jcr:name": "My Type"
      },
      "nl": {
        "myhippoproject:title": "Titel",
        "myhippoproject:title#hint": "Titel hint",
        "jcr:name": "Mijn Type"
      }
    }
  }
}
Did you find this page helpful?
How could this documentation serve you better?
On this page
    Did you find this page helpful?
    How could this documentation serve you better?