Problems, need help? Have a tip or advice? Post it here.
3 posts Page 1 of 1
I have an editable table that is setup via a repeatable region, it's fully working for display purposes on the site. However, I need to be able to take some of the data within the table and use it in another location. Is there a specific way to address a repeatable value?

For example:

Row 1 contains this data: Value 1
Row 2 contains this data: Value 2
Row 3 contains this data: Value 3

Is there anyway to address Row 2 and put that data into a variable?

I've been experimenting within the show_repeatable in this fashion:

Code: Select all
<cms:show_repeatable 'value_table'>
<cms:set dynamicvalue=table_data />
</cms:show_repeatable>


However, it only outputs: Value 3

I've also tried the obvious by entering table_data[1] in the set line to try and address an array to no avail.
Code: Select all
<cms:show_repeatable 'value_table'>
   <cms:dump />
</cms:show_repeatable>

That should help you see the available variables. It will also answer the question about Value 3, since it's the last value in the table.
Join COUCH:TALK channel here https://t.me/couchcms_chat
Ryazania — a framework to boost productivity with Add-ons viewtopic.php?f=2&t=13475
Support my efforts to help the community https://boosty.to/trendo/donate
Hi Matt!

Please check https://www.couchcms.com/forum/viewtopic.php?f=8&t=9484 Maybe it will help you :)

Nea Pandele
3 posts Page 1 of 1