So I am using bootstrap and I want to generate how many numbers there are in the list so that it can assign how many columns there should be and generate the proper number:
i.e. class="col-md-#" and # be populated by how many there are in the list...what's the best way to do this?
Also, how do I assign a class based a drop-down so I can set it as "default" or "featured" and if it's set to featured, it would add class="featured"? Will it work if I just called the custom field name and it would populate it with the value?
Thanks in advance for any guidance.
LISE Population for classes?
Re: LISE Population for classes?
Though I think you don't want it this way you can easily get the number of items. From the sample summary template:
Code: Select all
{if $items|@count > 0}
Code: Select all
class="col-md-{$items|@count}
Yes, did you try it?Also, how do I assign a class based a drop-down so I can set it as "default" or "featured" and if it's set to featured, it would add class="featured"? Will it work if I just called the custom field name and it would populate it with the value?