1
0
Fork 0
django-blog/blog/templates/base_blog.html
2012-11-25 22:10:09 +01:00

63 lines
No EOL
1.6 KiB
HTML

{% extends "base.html" %}
{% load blog_tags %}
{% block title %}{% blog_title %}{% endblock %}
{% block rss %}
<link rel="alternate" type="application/rss+xml"
title="{% blog_title %}: Latest entries"
href="{% url latest-entries-feed %}">
{% get_content blog.category as categories %}
{% if categories %}
{% for category in categories %}
<link rel="alternate" type="application/rss+xml"
title="{% blog_title %}: Latest entries in category {{ category.name }}"
href="{% url latest-category-entries-feed category.slug %}">
{% endfor %}
{% endif %}
{% endblock %}
{% block sidebar %}
{% get_months_archive as months %}
{% if months_archive %}
<h3>Archives</h3>
<ul>
{% for month in months_archive %}
<li>
<a href="{% url blog_entry_archive_month month.year month.month %}">
{{ month|date:"F Y" }}
</a>
</li>
{% endfor %}
</ul>
{% endif %}
{% get_content blog.category as categories %}
{% if categories %}
<h3>Categories</h3>
<ul>
{% for category in categories %}
<li>
<a href="{% url blog_category_detail category.slug %}">
{{ category }}
</a>
</li>
{% endfor %}
</ul>
{% endif %}
{% get_content blog.link as links %}
{% if links %}
<h3>Blogroll</h3>
<ul>
{% for link in links %}
<li>
<a href="{{ link.url }}">
{{ link.title }}
</a>
</li>
{% endfor %}
</ul>
{% endif %}
{% endblock %}