Intro-to-Jinja-tpl-v2/templates/results.html

17 lines
359 B
HTML
Raw Normal View History

2024-02-12 16:39:27 +00:00
{# templates/results.html #}
{% extends "base.html" %}
2024-02-12 16:39:27 +00:00
{% block content %}
<h1>{{ test_name }} {{ title }}: </h1>
2024-02-12 16:39:27 +00:00
<ul>
{% for student in students %}
2024-02-13 11:24:27 +00:00
<li>
{% if student.score > 80 %} :-) {% else %} :-( {% endif %}
2024-02-12 16:39:27 +00:00
<em>{{ student.name }}:</em> {{ student.score }}/{{ max_score }}
</li>
{% endfor %}
</ul>
{% endblock content %}