- This topic has 6 replies, 2 voices, and was last updated 1 year, 6 months ago by .
-
Topic
-
I want to create a for loop to render a clonable text field in order to create LIs.
<ul id="pros-list"> {% for i in pros %} <li>{{i}}</li> {% endfor %} </ul>
That’s based on the example in Twig, but I realize that it won’t get the array in my custom field called “pros” because it isn’t between brackets, the issue is that if I add {{pros}} inside any kind of {% %} it crashes WP.
Also, I want to do a math equation with the fields, something like ({{a}} + {{b}})/2, how can I achieve that?
Thanks in advance!
Cheers.
Viewing 6 replies - 1 through 6 (of 6 total)
Viewing 6 replies - 1 through 6 (of 6 total)
- You must be logged in to reply to this topic.