Increment a variable in a loop
-
Hi,
Do you think it’s possible to increment a variable set with CCS?
I need this inside an ACF[related]
:[related my_acf_relationship] [set id_count]0[/set] [here something magic to increment the var on each loop cycle] [pass vars] <a href="#{ID_COUNT}">My link {ID_COUNT}</a> [/pass] [/related]
Given i have 3 related items, it would return this:
<a href="#1">My link 1</a> <a href="#2">My link 2</a> <a href="#3">My link 3</a>
I tried to use CCS [calc] without sucess.
Thanks for your help!
Viewing 3 replies - 1 through 3 (of 3 total)
Viewing 3 replies - 1 through 3 (of 3 total)
- The topic ‘Increment a variable in a loop’ is closed to new replies.