I have a list of 16 results, let\'s call it \"results\". I want to arrange them in a 4 x 4 table.
Using the django template, how can I do this? (It doesn\'t seem like cy
You can use the cycle tag for this.
cycle
{% for r in results %} {% cycle '' '' '' '' %} {{r.content}} {% cycle '' '' '' '' %} {% endfor %}
Would output something like...
result 1 result 2 result 3 result 4 result 5 result 6 result 7 result 8