{% if errors %} Please correct the following errors and re-upload. {% for e in errors %} Error: {{ e }} {% endfor %} {% else %} {% for item in sample_rows %} {% with sample=item %} {% include 'routine_histology_row.html' %} {% endwith %} {% endfor %} {% endif %}