Home > widget-integration > FilterUrlHelper > getMultipleValueSeparator

FilterUrlHelper.getMultipleValueSeparator() method

Gets the configured separator for multiple values in a URL parameter.

Returns the separator character used to combine multiple filter values in a single URL parameter (URL scheme 2). Override this method to use custom separators for specific shops or regions.

The result is cached for performance since this method may be called frequently during URL parsing and construction.

Signature:

protected getMultipleValueSeparator(): string;

Returns:

string

The separator character (defaults to ',')

Example 1

Use pipe separator:

protected getMultipleValueSeparator(): string {
  return '|'; // Better for URLs with commas in values
}

Example 2

Regional separator based on shop locale:

protected getMultipleValueSeparator(): string {
  const locale = this.store.getState('shopLocale');
  return locale === 'de' ? ';' : ',';
}