D
D
Dmitry Vyatkin2015-09-06 22:25:46
Django
Dmitry Vyatkin, 2015-09-06 22:25:46

What is the correct way to add a numbered list in a Django template?

{% for table in table %}
    <tr>
      <td>
         <ol><li></li></ol>
      </td>
      <td>
       {{ data }}
      </td>
    </tr>
      {% endfor %}

How to make the numbering work?

Answer the question

In order to leave comments, you need to log in

2 answer(s)
S
sim3x, 2015-09-06
@dim137

{{ forloop.counter }}
https://docs.djangoproject.com/en/1.8/ref/template...

A
Artem Klimenko, 2015-09-06
@aklim007

htmlbook.ru/html/ol

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question