{% extends "base.html" %}

{% block header %}Neuigkeiten - Übersicht {% endblock %}
{% block headline %}Neuigkeiten{% endblock %}

{% block content %}
{% autoescape off %}
{% if category %}
<h1>Blog posts for category {{ category }}</h1>
{% endif %}
{% if blogentries %}
{% for blogentry in blogentries %}
{% if blogentry.published %}
<h1>{{ blogentry.header }}</h1>
<small>posted on: {{blogentry.date}} by {{blogentry.user.username}}</small>
<p>{{blogentry.intro|linebreaks}}
<small>Filed under: {% for category in blogentry.categories.all %} <a href="{% url 'category' category.id %}">{{ category }}</a> {% endfor %}</small>
</p><a href="{% url 'detail' blogentry.id %}">Read more...</a><br/>
{% endif %}
{% endfor %}
{% else %}
<p>No entries are available.</p>
{% endif %}
{% endautoescape %}
{% endblock %}

