CMS Development

kyKaq
Member

Problem with repeater unique id

SOLVE

I use the html id {{ name }}. However, it returns to the same unique id.

I want to do repeater in repeater. Then the second repeater (inner one) can set the setting such as width and height of the item. The setting can enable me to do somethings like item in first repeater is smaller but the item in second repeater is larger.

PS: I had enable the repeater option of row and Repeater.

kyKaq_1-1605666655262.pngkyKaq_2-1605666717010.pngkyKaq_3-1605666755246.png

 

0 Upvotes
1 Accepted solution
piersg
Solution
Key Advisor

Problem with repeater unique id

SOLVE

{{name}} is a default value in HubL that returns the module instance id, as you can see. You could use module-{{loop.index}} which will give you "module-1" "module-2" and so on, for as many iterations as you add.

View solution in original post

2 Replies 2
kyKaq
Member

Problem with repeater unique id

SOLVE

It solves the problem, thanks for your solution

 

0 Upvotes
piersg
Solution
Key Advisor

Problem with repeater unique id

SOLVE

{{name}} is a default value in HubL that returns the module instance id, as you can see. You could use module-{{loop.index}} which will give you "module-1" "module-2" and so on, for as many iterations as you add.