{% load markup %}
{% block content %}
-<h1>{{ title }}</h1>
-{{ content|restructuredtext }}
+<h1>{{ entry.title }}</h1>
+{{ entry.content|restructuredtext }}
+<p>Posted: {{ entry.publish_date|date:"Y-m-d H:i" }}
+ {% if entry.sections.count %}
+ in
+ {% for section in entry.sections.all %}
+ {% if forloop.first %}
+ <a href="{{ section.get_absolute_url }}">{{ section.title }}</a>{% if not forloop.last %}, {% endif %}
+ {% else %}
+ {% if forloop.last %}
+ and <a href="{{ section.get_absolute_url }}">{{ section.title }}</a>
+ {% else %}
+ <a href="{{ section.get_abolute_url }}">{{ section.title }}</a>
+ {% endif %}
+ {% endif %}
+ {% endfor %}
+ {% endif %}
+ <a href="{{ entry.get_absolute_url }}">permalink</a>
+</p>
{% endblock %}
t = loader.get_template(template_name)
c = RequestContext(request,
{
- "content": blog_entry.content,
- "title": blog_entry.title,
+ "entry": blog_entry,
"publish_date": blog_entry.publish_date
}
)