Skip to content

Formats

Different parts of eSales uses different methods to tokenize and order data. How the methods work depends in part on how the data is formatted. For example, an argument in a panel query may need a specific string format to work correctly. Likewise, incorrectly formated locale data in a query may affect sorting of phrases.

String separator formats

When configuring attributes or supplying arguments in a panel query there are use cases where a string can include multiple values. Depending on context different methods to separate a string into values are used.

No format

The string will not be separated and treated as one whole value.

Comma-separated list

A comma-separated list is a string where each value is separated by a comma character, ,. For example, a string with the value title,author,language is treated as three separate values: title, author , and language.

Pipe-separated list

A pipe-separated list is a string where each value is separated by a pipe character, |. For example, a string with the value title|author, year|language is treated as three separate values: title, author, year, and language.

HTML

Values are produced from HTML fragments where HTML elements are used as value splitting separators. White spaces between elements are discarded and common escape sequences are decoded. Special HTML elements such as <script> and <style> are discarded entirely. For example, the HTML fragment <ul> <li>Jurassic Park</li> <li>Michael Crichton</li> <li>English</li> </ul> is treated as three separate values: Jurassic Park, Michael Crichton , and English.

Path

A path is a string where each level of a path is separated by the backslash character, /. Each parent path in the string will be a separate value. For example, the value /clothing/sports/basketball is treated as three separate values: /clothing/sports/basketball, /clothing/sports, and /clothing.

Comma-separated list of paths

A combination of the Comma-separated list and the Path formats. The string will first be split into values based on the comma character, ,. The values are then separated into paths by the backslash character, /. For example, a string with the value /clothing/sports,/accessories/bags will be treated as four separate values: /clothing/sports, /clothing, /accessories/bags, and /accessories.

Pipe-separated list of paths

A combination of the Pipe-separated list and the Path formats. The string will first be split into values based on the pipe character, |. The values are then separated into paths by the backslash character, /. For example, a string with the value /clothing/sports|/accessories/bags will be treated as four separate values: /clothing/sports, /clothing, /accessories/bags, and /accessories.

Locale format

The Java 8 implementation of the IETF language tag BCP 47 format is used for locales within Apptus eSales. A locale usually consists of at least a sub-tag for the language identifier and a sub-tag for the region identifier. Sub-tags are separated by a hyphen, -.

The language identifier is usually in lower case and the region identifier in upper case. The complete language tag used as a locale with English (en) as the language identifier and Great Britain (GB) as a region identifier will be en-GB.

A locale can have an additional sub-tag for extended standard language tags such as zh-Hant-CN where a script identifier, Hant, for Traditional Chinese is included to separate it from Simplified Chinese, Hans. Sub-tags for variants and extensions can be added to the locale, however this is not commonly used.

Backwards compatibility

Pre-Java 8 formatting of locales using an underscore, _, as a sub-tag separator instead of a hyphen, -, is supported by eSales. Note that the pre-Java 8 formatting of sub-tags differ from Java 8 formatting.

Standard locales are recommended to use but custom locale formats can be used as well, as long as it is following the formatting of at least a sub-tag for the language identifier, a sub-tag for the region identifier, and hyphens as separators. Examples of non-standard locales are en-CN (English in China) and en-SE (English in Sweden).

×