Skip to content

Output Color Attribute as List#


Description#

Get Attributes for Color Output pipe (|) separated list

<mvt:comment>
| Get Attributes for Color
| Output pipe (|) separated list
</mvt:comment>

<mvt:assign name="g.color_list" value="''" />

<mvt:foreach iterator="color" array="record:attributes:color">
<mvt:assign name="g.color_list" value="g.color_list $ l.settings:color $ '|'" />
</mvt:foreach>

<mvt:assign name="g.color_list" value="substring( g.color_list, 1, len( g.color_list )-1 )" />
<mvt:assign name="g.color_list" value="miva_csv_encode( g.color_list, '|' )" />

Output: &mvt:global:color_list;

Functions Used#

  • substring
  • miva_csv_encode