Changeset 911
- Timestamp:
- 10/17/05 13:08:55 (3 years ago)
- Files:
-
- django/trunk/docs/templates.txt (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
django/trunk/docs/templates.txt
r905 r911 400 400 401 401 {% if athlete_list %} 402 Number of athletes: {{ athlete_list| count}}402 Number of athletes: {{ athlete_list|length }} 403 403 {% else %} 404 404 No athletes. … … 406 406 407 407 In the above, if ``athlete_list`` is not empty, the number of athletes will be 408 displayed by the ``{{ athlete_list| count}}`` variable.408 displayed by the ``{{ athlete_list|length }}`` variable. 409 409 410 410 As you can see, the ``if`` tag can take an option ``{% else %}`` clause that … … 433 433 {% if athlete_list %} 434 434 {% if coach_list %} 435 Number of athletes: {{ athlete_list| count}}.436 Number of coaches: {{ coach_list| count}}.435 Number of athletes: {{ athlete_list|length }}. 436 Number of coaches: {{ coach_list|length }}. 437 437 {% endif %} 438 438 {% endif %}
