Muut
1
we just try to add a separator after each 2column inside loop we when we write code like below we getting error
{% set i=2 %}
{% for ps in taxonomy.findTaxonomy({‘Post Type’:[page.title]}) %}
statement ------------
{% if(i%2==0)%}
{% endif%}
{% i++ %}
{% endfor %}
anyone can help me how we set
Thanks
Muut
2
Why not just add the seperator via CSS? You can use nth-child selector without any extra HTML.
Muut
3
no i just want to be from it any idea??
how we set
Muut
4
can you please give me soluation how we set
Muut
5
Have a look at the loop variable if you would prefer to add something via Twig/HTML: http://twig.sensiolabs.org/doc/tags/for.html#the-loop-variable
Muut
6
if we want to be write some thing like above any idea how to set it
when we set i++ it giving error
Muut
7
Now i got the solution here we can set
{% set i = 1 %}
{% for ps in taxonomy.findTaxonomy({‘Post Type’:‘blog’})|slice(0, 10) %}
{% if(i%2==0)%}
for separtor
{% endif%}
{% set i = i + 1 %}
{% endfor %}
we can used something like above
Thanks