Use Locale and LocaleMap for images | Scene7

Issue

Can I set up the LocaleMap in SPS to call different images based on language or regional requirements?

Solution

You set up the locale lookup map in SPS Application Setup > Publish Setup > Image Server. For more information, see http://microsite.omniture.com/t2/help/en_US/s7/is_ir_api/#LocaleMap

Example:

  1. Set Default Locale to en.
  2. Set Locale Map to en,_en,|he,_he|zh,_zh|de,_de,.
  3. Upload three images titled "hello," 'hello_he," and "hello_zh."

http://test-e4.scene7.com/is/image/OmniPS/hello
http://test-e4.scene7.com/is/image/OmniPS/hello?locale=en
http://test-e4.scene7.com/is/image/OmniPS/hello?locale=zh
http://test-e4.scene7.com/is/image/OmniPS/hello?locale=he

If you try a URL that does not have a locale defined in the Locale Map, a 404 error occurs:
http://test-e4.scene7.com/is/image/OmniPS/hello?locale=fr

The error includes this message:
"Unknown locale: fr - no default rule defined."

If you now want to support France, add | Fr, _fr, to the locale map, and add an image called "hello_fr."

But, if you call the German locale (de) http://test-e4.scene7.com/is/image/OmniPS/hello?locale=de, the Locale Map is defined for de, but no image called "image_de" exists. So it fails back to the default image--in this case, en ("hello").

Locale, as it is today, only applies if you append the locale given in the locale map.

There is no translation of the members of a set, as it is assumed each is called individually with the locale to translate.

Actually, it is a lookup mechanism, which should provide the default locale if the locale map is properly configured.

You can check the lookup order using &req=xlate

http://s7e4a.scene7.com/is/image/OmniPS/hello?locale=en&req=xlate

Because you defined: en,_en, it also looks for "hello" and not only for "hello_en."

 Adobe

Get help faster and easier

New user?