diff --git a/.travis.yml b/.travis.yml
index 606305ec7..ce95b9a49 100644
--- a/.travis.yml
+++ b/.travis.yml
@@ -5,9 +5,10 @@ python:
install:
- pip install -U setuptools
- python bootstrap.py
- - ./bin/buildout -c ci/travis.cfg
+ - ./bin/buildout -c travis.cfg
before_script:
- - make kwalitee
+ - ./bin/pyflakes zinnia
+ - ./bin/pep8 --count --show-source --statistics --exclude=migrations zinnia
script:
- ./bin/test
after_success:
diff --git a/ci/shiningpanda.cfg b/ci/shiningpanda.cfg
deleted file mode 100644
index 58e5b0372..000000000
--- a/ci/shiningpanda.cfg
+++ /dev/null
@@ -1,26 +0,0 @@
-[buildout]
-extends = ../buildout.cfg
-
-develop = ..
-
-bin-directory = ../bin
-
-parts-directory = ../parts
-
-eggs-directory = ../eggs
-
-develop-eggs-directory = ../develop-eggs
-
-parts = cover
- pep8
- pyflakes
-
-eggs -= tweepy
- gdata
- feedparser
- South
- akismet
- PyMollom
- pdbpp
- nose-progressive
-
diff --git a/demo/settings.py b/demo/settings.py
index ee9b0c214..855b7fa0e 100644
--- a/demo/settings.py
+++ b/demo/settings.py
@@ -4,6 +4,7 @@
gettext = lambda s: s
DEBUG = True
+TEMPLATE_DEBUG = DEBUG
DATABASES = {'default':
{'ENGINE': 'django.db.backends.sqlite3',
diff --git a/docs/development/tests.rst b/docs/development/tests.rst
index 50e0e9cd0..d411f1239 100644
--- a/docs/development/tests.rst
+++ b/docs/development/tests.rst
@@ -51,7 +51,7 @@ Coverage
Despite my best efforts, some functionnalities are not yet tested, that's why
I need your help !
-As I write these lines the **175** tests in Zinnia cover **96%** of the code
+As I write these lines the **182** tests in Zinnia cover **96%** of the code
bundled in Zinnia. A real effort has been made to obtain this percentage,
for ensuring the quality of the code.
diff --git a/ci/travis.cfg b/travis.cfg
similarity index 63%
rename from ci/travis.cfg
rename to travis.cfg
index f3873cce3..7289c0656 100644
--- a/ci/travis.cfg
+++ b/travis.cfg
@@ -1,20 +1,13 @@
[buildout]
-extends = ../buildout.cfg
-
-develop = ..
-
-bin-directory = ../bin
-
-parts-directory = ../parts
-
-eggs-directory = ../eggs
-
-develop-eggs-directory = ../develop-eggs
+extends = buildout.cfg
parts = test
+ pep8
+ pyflakes
coveralls
-eggs -= tweepy
+eggs -= django-bitly
+ tweepy
gdata
feedparser
South
diff --git a/zinnia/templates/403.html b/zinnia/templates/403.html
index aa966914a..6aad4cd18 100644
--- a/zinnia/templates/403.html
+++ b/zinnia/templates/403.html
@@ -5,11 +5,11 @@
-{% endblock %}
+{% endblock breadcrumbs %}
-{% block title %}{% trans "Permission denied" %}{% endblock %}
+{% block title %}{% trans "Permission denied" %}{% endblock title %}
-{% block body-class %}error-403{% endblock %}
+{% block body-class %}error-403{% endblock body-class %}
{% block content %}
{% trans "Permission denied" %}
@@ -17,4 +17,4 @@ {% trans "Permission denied" %}
{% trans "Sorry but you don't have the permission to do this action." %}
{{ block.super }}
-{% endblock %}
+{% endblock content %}
diff --git a/zinnia/templates/404.html b/zinnia/templates/404.html
index 53b9760fa..4e2b468ec 100644
--- a/zinnia/templates/404.html
+++ b/zinnia/templates/404.html
@@ -5,11 +5,11 @@
-{% endblock %}
+{% endblock breadcrumbs %}
-{% block title %}{% trans "Page not found" %}{% endblock %}
+{% block title %}{% trans "Page not found" %}{% endblock title %}
-{% block body-class %}error-404{% endblock %}
+{% block body-class %}error-404{% endblock body-class %}
{% block content %}
{% trans "Page not found" %}
@@ -17,4 +17,4 @@ {% trans "Page not found" %}
{% trans "Sorry, but the requested page could not be found." %}
{{ block.super }}
-{% endblock %}
+{% endblock content %}
diff --git a/zinnia/templates/500.html b/zinnia/templates/500.html
index 050fc3213..023af01b3 100644
--- a/zinnia/templates/500.html
+++ b/zinnia/templates/500.html
@@ -5,11 +5,11 @@
-{% endblock %}
+{% endblock breadcrumbs %}
-{% block title %}{% trans "Server error" %}{% endblock %}
+{% block title %}{% trans "Server error" %}{% endblock title %}
-{% block body-class %}error-500{% endblock %}
+{% block body-class %}error-500{% endblock body-class %}
{% block content %}
{% trans "Server error" %}
@@ -17,4 +17,4 @@ {% trans "Server error" %}
{% trans "There's been an error. It's been reported to the site administrators via e-mail and should be fixed shortly. Thanks for your patience." %}
{{ block.super }}
-{% endblock %}
+{% endblock content %}
diff --git a/zinnia/templates/admin/zinnia/app_index.html b/zinnia/templates/admin/zinnia/app_index.html
index 520afdf07..06c693b5c 100644
--- a/zinnia/templates/admin/zinnia/app_index.html
+++ b/zinnia/templates/admin/zinnia/app_index.html
@@ -5,7 +5,7 @@
{{ block.super }}
-{% endblock %}
+{% endblock extrastyle %}
{% block extrahead %}
{{ block.super }}
@@ -21,7 +21,7 @@
});
});
-{% endblock %}
+{% endblock extrahead %}
{% block content %}
@@ -31,4 +31,4 @@
{% include "admin/zinnia/widgets/draft_entries.html" %}
{% include "admin/zinnia/widgets/recent_linkbacks.html" %}
-{% endblock %}
+{% endblock content %}
diff --git a/zinnia/templates/admin/zinnia/widgets/base.html b/zinnia/templates/admin/zinnia/widgets/base.html
index d0790cdfc..2c7952c08 100644
--- a/zinnia/templates/admin/zinnia/widgets/base.html
+++ b/zinnia/templates/admin/zinnia/widgets/base.html
@@ -1,6 +1,6 @@
-
-
- {% block title %}{% endblock %}
- {% block content %}{% endblock %}
+
+
+ {% block title %}{% endblock title %}
+ {% block content %}{% endblock content %}
diff --git a/zinnia/templates/admin/zinnia/widgets/content_stats.html b/zinnia/templates/admin/zinnia/widgets/content_stats.html
index b9752f465..7c7715797 100644
--- a/zinnia/templates/admin/zinnia/widgets/content_stats.html
+++ b/zinnia/templates/admin/zinnia/widgets/content_stats.html
@@ -1,12 +1,12 @@
{% extends "admin/zinnia/widgets/base.html" %}
{% load i18n zinnia_tags %}
-{% block module_id %}contents{% endblock %}
+{% block module_id %}contents{% endblock module_id %}
-{% block summary %}{% trans "Today" %}{% endblock %}
+{% block summary %}{% trans "Today" %}{% endblock summary %}
-{% block title %}{% trans "Today" %}{% endblock %}
+{% block title %}{% trans "Today" %}{% endblock title %}
{% block content %}
{% zinnia_statistics "admin/zinnia/widgets/_content_stats.html" %}
-{% endblock %}
+{% endblock content %}
diff --git a/zinnia/templates/admin/zinnia/widgets/draft_entries.html b/zinnia/templates/admin/zinnia/widgets/draft_entries.html
index edeb4a9df..bbf50de4c 100644
--- a/zinnia/templates/admin/zinnia/widgets/draft_entries.html
+++ b/zinnia/templates/admin/zinnia/widgets/draft_entries.html
@@ -1,12 +1,12 @@
{% extends "admin/zinnia/widgets/base.html" %}
{% load i18n zinnia_tags %}
-{% block module_id %}drafts{% endblock %}
+{% block module_id %}drafts{% endblock module_id %}
-{% block summary %}{% trans "Draft entries" %}{% endblock %}
+{% block summary %}{% trans "Draft entries" %}{% endblock summary %}
-{% block title %}{% trans "Draft entries" %}{% endblock %}
+{% block title %}{% trans "Draft entries" %}{% endblock title %}
{% block content %}
{% get_draft_entries template="admin/zinnia/widgets/_draft_entries.html" %}
-{% endblock %}
+{% endblock content %}
diff --git a/zinnia/templates/admin/zinnia/widgets/recent_comments.html b/zinnia/templates/admin/zinnia/widgets/recent_comments.html
index d8e2c02c1..e0bf349f7 100644
--- a/zinnia/templates/admin/zinnia/widgets/recent_comments.html
+++ b/zinnia/templates/admin/zinnia/widgets/recent_comments.html
@@ -1,12 +1,12 @@
{% extends "admin/zinnia/widgets/base.html" %}
{% load i18n zinnia_tags %}
-{% block module_id %}comments{% endblock %}
+{% block module_id %}comments{% endblock module_id %}
-{% block summary %}{% trans "Recent comments" %}{% endblock %}
+{% block summary %}{% trans "Recent comments" %}{% endblock summary %}
-{% block title %}{% trans "Recent comments" %}{% endblock %}
+{% block title %}{% trans "Recent comments" %}{% endblock title %}
{% block content %}
{% get_recent_comments template="admin/zinnia/widgets/_recent_comments.html" %}
-{% endblock %}
+{% endblock content %}
diff --git a/zinnia/templates/admin/zinnia/widgets/recent_linkbacks.html b/zinnia/templates/admin/zinnia/widgets/recent_linkbacks.html
index bfa120cdd..972d23273 100644
--- a/zinnia/templates/admin/zinnia/widgets/recent_linkbacks.html
+++ b/zinnia/templates/admin/zinnia/widgets/recent_linkbacks.html
@@ -1,12 +1,12 @@
{% extends "admin/zinnia/widgets/base.html" %}
{% load i18n zinnia_tags %}
-{% block module_id %}linkbacks{% endblock %}
+{% block module_id %}linkbacks{% endblock module_id %}
-{% block summary %}{% trans "Recent linkbacks" %}{% endblock %}
+{% block summary %}{% trans "Recent linkbacks" %}{% endblock summary %}
-{% block title %}{% trans "Recent linkbacks" %}{% endblock %}
+{% block title %}{% trans "Recent linkbacks" %}{% endblock title %}
{% block content %}
{% get_recent_linkbacks template="admin/zinnia/widgets/_recent_linkbacks.html" %}
-{% endblock %}
+{% endblock content %}
diff --git a/zinnia/templates/comments/zinnia/entry/posted.html b/zinnia/templates/comments/zinnia/entry/posted.html
index d4c9f4562..614c797a0 100644
--- a/zinnia/templates/comments/zinnia/entry/posted.html
+++ b/zinnia/templates/comments/zinnia/entry/posted.html
@@ -1,9 +1,9 @@
{% extends "zinnia/base.html" %}
{% load i18n %}
-{% block title %}{% trans "Thanks for your comment" %}{% endblock %}
+{% block title %}{% trans "Thanks for your comment" %}{% endblock title %}
-{% block body-class %}comment-posted{% endblock %}
+{% block body-class %}comment-posted{% endblock body-class %}
{% block content %}
{% trans "Thanks for your comment" %}
@@ -28,4 +28,4 @@ {% trans "Thanks for your comment" %}
-{% endblock %}
+{% endblock content %}
diff --git a/zinnia/templates/comments/zinnia_entry_preview.html b/zinnia/templates/comments/zinnia_entry_preview.html
index f8d7d2727..b76cb13d3 100644
--- a/zinnia/templates/comments/zinnia_entry_preview.html
+++ b/zinnia/templates/comments/zinnia_entry_preview.html
@@ -1,9 +1,9 @@
{% extends "zinnia/base.html" %}
{% load i18n zinnia_tags comments %}
-{% block title %}{% trans "Comment preview" %}{% endblock %}
+{% block title %}{% trans "Comment preview" %}{% endblock title %}
-{% block body-class %}comment-preview{% endblock %}
+{% block body-class %}comment-preview{% endblock body-class %}
{% block content %}
{% if form.errors %}
@@ -33,4 +33,4 @@ {% trans "Preview of the comment" %}
{% endif %}
{% include "comments/zinnia/entry/form.html" %}
-{% endblock %}
+{% endblock content %}
diff --git a/zinnia/templates/zinnia/_entry_detail_base.html b/zinnia/templates/zinnia/_entry_detail_base.html
index eff3b94f9..cfbcfe430 100644
--- a/zinnia/templates/zinnia/_entry_detail_base.html
+++ b/zinnia/templates/zinnia/_entry_detail_base.html
@@ -8,7 +8,7 @@
{{ object.title|widont }}
- {% endblock %}
+ {% endblock entry-title %}
{% block entry-info %}
{% block entry-authors %}
@@ -25,10 +25,10 @@
{% trans "Written on" %}
{% endif %}
{% endwith %}
- {% endblock %}
+ {% endblock entry-authors %}
{% block entry-published %}
{{ object.creation_date|date:"DATE_FORMAT" }}
- {% endblock %}
+ {% endblock entry-published %}
{% block entry-categories %}
{% with categories=object.categories.all %}
{% if categories|length %}
@@ -38,16 +38,16 @@
title="{% blocktrans %}Show all entries in {{ category }}{% endblocktrans %}"
rel="tag category">{{ category }}{% if not forloop.last %}, {% endif %}{% endfor %}{% endif %}.
{% endwith %}
- {% endblock %}
+ {% endblock entry-categories %}
- {% endblock %}
+ {% endblock entry-info %}
{% block entry-last-update %}
{% trans "Last update on" %} {{ object.last_update|date:"DATE_FORMAT" }}.
- {% endblock %}
+ {% endblock entry-last-update %}
- {% endblock %}
+ {% endblock entry-header %}
{% block entry-body %}
@@ -65,12 +65,12 @@
{% endif %}
- {% endblock %}
+ {% endblock entry-image %}
{% block entry-content %}
{{ object_content|safe }}
- {% endblock %}
+ {% endblock entry-content %}
{% block continue-reading %}
{% if continue_reading and object_content.has_more %}
@@ -81,9 +81,9 @@
{% endif %}
- {% endblock %}
+ {% endblock continue-reading %}
- {% endblock %}
+ {% endblock entry-body %}
{% block entry-footer %}
- {% endblock %}
+ {% endblock entry-footer %}
diff --git a/zinnia/templates/zinnia/author_list.html b/zinnia/templates/zinnia/author_list.html
index a0f120f65..53085a692 100644
--- a/zinnia/templates/zinnia/author_list.html
+++ b/zinnia/templates/zinnia/author_list.html
@@ -1,11 +1,11 @@
{% extends "zinnia/base.html" %}
{% load i18n %}
-{% block meta-description %}{% trans "Author list" %}{% endblock %}
+{% block meta-description %}{% trans "Author list" %}{% endblock meta-description %}
-{% block title %}{% trans "Authors" %}{% endblock %}
+{% block title %}{% trans "Authors" %}{% endblock title %}
-{% block body-class %}author-list{% endblock %}
+{% block body-class %}author-list{% endblock body-class %}
{% block content %}
{% trans "Author list" %}
@@ -24,4 +24,4 @@ {% trans "Author list" %}
{% endfor %}
-{% endblock %}
+{% endblock content %}
diff --git a/zinnia/templates/zinnia/base.html b/zinnia/templates/zinnia/base.html
index 07231d893..28b286744 100644
--- a/zinnia/templates/zinnia/base.html
+++ b/zinnia/templates/zinnia/base.html
@@ -1,11 +1,11 @@
{% extends "zinnia/skeleton.html" %}
{% load zinnia_tags i18n %}
-{% block meta-keywords %}{% get_tags as entry_tags %}{{ entry_tags|join:", "}}{% endblock %}
+{% block meta-keywords %}{% get_tags as entry_tags %}{{ entry_tags|join:", "}}{% endblock meta-keywords %}
{% block meta %}
-{% endblock %}
+{% endblock meta %}
{% block link %}
@@ -16,11 +16,11 @@
{% get_archives_entries "zinnia/tags/archives_entries_link.html" %}
-{% endblock %}
+{% endblock link %}
{% block breadcrumbs %}
{% zinnia_breadcrumbs %}
-{% endblock %}
+{% endblock breadcrumbs %}
{% block sidebar %}
{% endif %}
-{% endblock %}
+{% endblock sidebar %}
diff --git a/zinnia/templates/zinnia/category_list.html b/zinnia/templates/zinnia/category_list.html
index 16778f3c6..ea6c9288b 100644
--- a/zinnia/templates/zinnia/category_list.html
+++ b/zinnia/templates/zinnia/category_list.html
@@ -1,11 +1,11 @@
{% extends "zinnia/base.html" %}
{% load i18n mptt_tags %}
-{% block meta-description %}{% trans "Category list" %}{% endblock %}
+{% block meta-description %}{% trans "Category list" %}{% endblock meta-description %}
-{% block title %}{% trans "Categories" %}{% endblock %}
+{% block title %}{% trans "Categories" %}{% endblock title %}
-{% block body-class %}category-list{% endblock %}
+{% block body-class %}category-list{% endblock body-class %}
{% block content %}
{% trans "Category list" %}
@@ -29,4 +29,4 @@ {% trans "Category list" %}
{% endif %}
-{% endblock %}
+{% endblock content %}
diff --git a/zinnia/templates/zinnia/entry_archive.html b/zinnia/templates/zinnia/entry_archive.html
index 7dd97bf48..548bdddb3 100644
--- a/zinnia/templates/zinnia/entry_archive.html
+++ b/zinnia/templates/zinnia/entry_archive.html
@@ -1,15 +1,15 @@
{% extends "zinnia/entry_list.html" %}
{% load i18n zinnia_tags %}
-{% block meta-description %}{% trans "Latest entries" %}{% endblock %}
+{% block meta-description %}{% trans "Latest entries" %}{% endblock meta-description %}
-{% block title %}{% trans "Latest entries" %}{% endblock %}
+{% block title %}{% trans "Latest entries" %}{% endblock title %}
-{% block body-class %}{{ block.super }} archive index {% now "\y\e\a\r-Y \m\o\n\t\h-m \w\e\ek-W \d\a\y-d" %}{% endblock %}
+{% block body-class %}{{ block.super }} archive index {% now "\y\e\a\r-Y \m\o\n\t\h-m \w\e\ek-W \d\a\y-d" %}{% endblock body-class %}
{% block slider %}
{% get_featured_entries template="zinnia/tags/slider_entries.html" %}
-{% endblock %}
+{% endblock slider %}
{% block content-related %}
{% if date_list %}
@@ -22,4 +22,4 @@ {% trans "Yearly archives" %}
{% endfor %}
{% endif %}
-{% endblock %}
+{% endblock content-related %}
diff --git a/zinnia/templates/zinnia/entry_archive_day.html b/zinnia/templates/zinnia/entry_archive_day.html
index 657bed2f2..01c55fa55 100644
--- a/zinnia/templates/zinnia/entry_archive_day.html
+++ b/zinnia/templates/zinnia/entry_archive_day.html
@@ -1,15 +1,15 @@
{% extends "zinnia/entry_list.html" %}
{% load i18n %}
-{% block meta-description %}{% trans "Archives" %} {{ day|date:"DATE_FORMAT" }}{% endblock %}
+{% block meta-description %}{% trans "Archives" %} {{ day|date:"DATE_FORMAT" }}{% endblock meta-description %}
-{% block title %}{% trans "Archives" %} {{ day|date:"DATE_FORMAT" }}{% endblock %}
+{% block title %}{% trans "Archives" %} {{ day|date:"DATE_FORMAT" }}{% endblock title %}
-{% block body-class %}{{ block.super }} archive date day year-{{ day|date:"Y" }} month-{{ day|date:"m" }} week-{{ day|date:"W" }} day-{{ day|date:"d" }}{% endblock %}
+{% block body-class %}{{ block.super }} archive date day year-{{ day|date:"Y" }} month-{{ day|date:"m" }} week-{{ day|date:"W" }} day-{{ day|date:"d" }}{% endblock body-class %}
{% block content-title %}
{% trans "Archives" %} {{ day|date:"DATE_FORMAT" }}
-{% endblock %}
+{% endblock content-title %}
{% block content-related %}
{% if previous_day %}
@@ -44,4 +44,4 @@ {% trans "Archives" %}
{% endif %}
-{% endblock %}
+{% endblock content-related %}
diff --git a/zinnia/templates/zinnia/entry_archive_month.html b/zinnia/templates/zinnia/entry_archive_month.html
index bffff1fe8..1f83ac67b 100644
--- a/zinnia/templates/zinnia/entry_archive_month.html
+++ b/zinnia/templates/zinnia/entry_archive_month.html
@@ -1,15 +1,15 @@
{% extends "zinnia/entry_list.html" %}
{% load i18n %}
-{% block meta-description %}{% trans "Archives" %} {{ month|date:"YEAR_MONTH_FORMAT" }}{% endblock %}
+{% block meta-description %}{% trans "Archives" %} {{ month|date:"YEAR_MONTH_FORMAT" }}{% endblock meta-description %}
-{% block title %}{% trans "Archives" %} {{ month|date:"YEAR_MONTH_FORMAT" }}{% endblock %}
+{% block title %}{% trans "Archives" %} {{ month|date:"YEAR_MONTH_FORMAT" }}{% endblock title %}
-{% block body-class %}{{ block.super }} archive date month year-{{ month|date:"Y" }} month-{{ month|date:"m" }}{% endblock %}
+{% block body-class %}{{ block.super }} archive date month year-{{ month|date:"Y" }} month-{{ month|date:"m" }}{% endblock body-class %}
{% block content-title %}
{% trans "Archives" %} {{ month|date:"YEAR_MONTH_FORMAT" }}
-{% endblock %}
+{% endblock content-title %}
{% block content-related %}
{% trans "Daily archives" %}
@@ -39,4 +39,4 @@ {% trans "Archives" %}
{{ month|date:"Y" }}
-{% endblock %}
+{% endblock content-related %}
diff --git a/zinnia/templates/zinnia/entry_archive_today.html b/zinnia/templates/zinnia/entry_archive_today.html
index cc04e6e9a..2fcc95527 100644
--- a/zinnia/templates/zinnia/entry_archive_today.html
+++ b/zinnia/templates/zinnia/entry_archive_today.html
@@ -1,15 +1,15 @@
{% extends "zinnia/entry_list.html" %}
{% load i18n %}
-{% block meta-description %}{% trans "Today archives" %} {{ day|date:"DATE_FORMAT" }}{% endblock %}
+{% block meta-description %}{% trans "Today archives" %} {{ day|date:"DATE_FORMAT" }}{% endblock meta-description %}
-{% block title %}{% trans "Today archives" %} {{ day|date:"DATE_FORMAT" }}{% endblock %}
+{% block title %}{% trans "Today archives" %} {{ day|date:"DATE_FORMAT" }}{% endblock title %}
-{% block body-class %}{{ block.super }} archive date today year-{{ day|date:"Y" }} month-{{ day|date:"m" }} week-{{ day|date:"W" }} day-{{ day|date:"d" }}{% endblock %}
+{% block body-class %}{{ block.super }} archive date today year-{{ day|date:"Y" }} month-{{ day|date:"m" }} week-{{ day|date:"W" }} day-{{ day|date:"d" }}{% endblock body-class %}
{% block content-title %}
{% trans "Today archives" %}
-{% endblock %}
+{% endblock content-title %}
{% block content-related %}
{% if previous_day %}
@@ -33,4 +33,4 @@ {% trans "Archives" %}
{{ day|date:"YEAR_MONTH_FORMAT" }}
-{% endblock %}
+{% endblock content-related %}
diff --git a/zinnia/templates/zinnia/entry_archive_week.html b/zinnia/templates/zinnia/entry_archive_week.html
index 39e1cfec6..920c33b04 100644
--- a/zinnia/templates/zinnia/entry_archive_week.html
+++ b/zinnia/templates/zinnia/entry_archive_week.html
@@ -1,16 +1,16 @@
{% extends "zinnia/entry_list.html" %}
{% load i18n %}
-{% block meta-description %}{% blocktrans with year=week|date:"Y" week_number=week|date:"W"%}Archives week {{ week_number }} of {{ year }}{% endblocktrans %}{% endblock %}
+{% block meta-description %}{% blocktrans with year=week|date:"Y" week_number=week|date:"W"%}Archives week {{ week_number }} of {{ year }}{% endblocktrans %}{% endblock meta-description %}
-{% block title %}{% blocktrans with year=week|date:"Y" week_number=week|date:"W"%}Archives week {{ week_number }} of {{ year }}{% endblocktrans %}{% endblock %}
+{% block title %}{% blocktrans with year=week|date:"Y" week_number=week|date:"W"%}Archives week {{ week_number }} of {{ year }}{% endblocktrans %}{% endblock title %}
-{% block body-class %}{{ block.super }} archive date week year-{{ week|date:"Y" }} month-{{ week|date:"m" }} week-{{ week|date:"W" }}{% endblock %}
+{% block body-class %}{{ block.super }} archive date week year-{{ week|date:"Y" }} month-{{ week|date:"m" }} week-{{ week|date:"W" }}{% endblock body-class %}
{% block content-title %}
{% blocktrans with year=week|date:"Y" week_number=week|date:"W" %}Archives week {{ week_number }} of {{ year }}{% endblocktrans %}
{{ week|date:"DATE_FORMAT" }} - {{ week_end_day|date:"DATE_FORMAT" }}
-{% endblock %}
+{% endblock content-title %}
{% block content-related %}
{% if previous_week %}
@@ -38,4 +38,4 @@ {% trans "Archives" %}
{{ week|date:"YEAR_MONTH_FORMAT" }}
-{% endblock %}
+{% endblock content-related %}
diff --git a/zinnia/templates/zinnia/entry_archive_year.html b/zinnia/templates/zinnia/entry_archive_year.html
index dd4d78374..4495bd9e6 100644
--- a/zinnia/templates/zinnia/entry_archive_year.html
+++ b/zinnia/templates/zinnia/entry_archive_year.html
@@ -1,15 +1,15 @@
{% extends "zinnia/entry_list.html" %}
{% load i18n %}
-{% block meta-description %}{% trans "Archives" %} {{ year|date:"Y" }}{% endblock %}
+{% block meta-description %}{% trans "Archives" %} {{ year|date:"Y" }}{% endblock meta-description %}
-{% block title %}{% trans "Archives" %} {{ year|date:"Y" }}{% endblock %}
+{% block title %}{% trans "Archives" %} {{ year|date:"Y" }}{% endblock title %}
-{% block body-class %}{{ block.super }} archive date year year-{{ year|date:"Y" }}{% endblock %}
+{% block body-class %}{{ block.super }} archive date year year-{{ year|date:"Y" }}{% endblock body-class %}
{% block content-title %}
{% trans "Archives" %} {{ year|date:"Y" }}
-{% endblock %}
+{% endblock content-title %}
{% block content-related %}
{% trans "Monthly archives" %}
@@ -33,4 +33,4 @@ {% trans "Next year" %}
{{ next_year|date:"Y" }}
{% endif %}
-{% endblock %}
+{% endblock content-related %}
diff --git a/zinnia/templates/zinnia/entry_detail_base.html b/zinnia/templates/zinnia/entry_detail_base.html
index c4ebc5b44..159d35e12 100644
--- a/zinnia/templates/zinnia/entry_detail_base.html
+++ b/zinnia/templates/zinnia/entry_detail_base.html
@@ -1,11 +1,11 @@
{% extends "zinnia/base.html" %}
{% load i18n comments zinnia_tags %}
-{% block title %}{{ object.title }}{% endblock %}
+{% block title %}{{ object.title }}{% endblock title %}
-{% block meta-description %}{{ object.excerpt|safe }}{% endblock %}
+{% block meta-description %}{{ object.excerpt|safe }}{% endblock meta-description %}
-{% block meta-keywords %}{% if object.tags %}{{ object.tags }}{% else %}{{ block.super }}{% endif %}{% endblock %}
+{% block meta-keywords %}{% if object.tags %}{{ object.tags }}{% else %}{{ block.super }}{% endif %}{% endblock meta-keywords %}
{% block link %}
{{ block.super }}
@@ -27,15 +27,15 @@
{% endwith %}
-{% endblock %}
+{% endblock link %}
-{% block body-class %}entry entry-{{ object.pk }}{% if object.featured %} featured{% endif %} year-{{ object.creation_date|date:"Y" }} month-{{ object.creation_date|date:"m" }} week-{{ object.creation_date|date:"W" }} day-{{ object.creation_date|date:"d" }}{% endblock %}
+{% block body-class %}entry entry-{{ object.pk }}{% if object.featured %} featured{% endif %} year-{{ object.creation_date|date:"Y" }} month-{{ object.creation_date|date:"m" }} week-{{ object.creation_date|date:"W" }} day-{{ object.creation_date|date:"d" }}{% endblock body-class %}
{% block content %}
{% block entry-content %}
{% include object.content_template with object_content=object.html_content %}
-{% endblock %}
+{% endblock entry-content %}
{% block entry-widgets %}
@@ -52,7 +52,7 @@
{% trans "Next entry" %}
{% endif %}
{% endwith %}
- {% endblock %}
+ {% endblock entry-next-entry %}
{% block entry-previous-entry %}
{% with previous_entry=object.previous_entry %}
{% if previous_entry %}
@@ -66,7 +66,7 @@ {% trans "Previous entry" %}
{% endif %}
{% endwith %}
- {% endblock %}
+ {% endblock entry-previous-entry %}
{% block entry-related-entries %}
{% with entry_related=object.related_published %}
{% if entry_related %}
@@ -82,15 +82,15 @@ {% trans "Related entries" %}
{% endif %}
{% endwith %}
- {% endblock %}
+ {% endblock entry-related-entries %}
{% block entry-similar-entries %}
{% trans "Similar entries" %}
{% get_similar_entries %}
- {% endblock %}
+ {% endblock entry-similar-entries %}
-{% endblock %}
+{% endblock entry-widgets %}
{% block entry-comments %}
-{% endblock %}
+{% endblock entry-comments %}
{% block entry-pingbacks %}
@@ -169,7 +169,7 @@
{% trans "Pingbacks" %}
{% trans "Pingbacks are closed." %}
{% endif %}
-{% endblock %}
+{% endblock entry-pingbacks %}
{% block entry-trackbacks %}
{% if object.trackback_count or object.trackbacks_are_open %}
@@ -207,17 +207,17 @@ {% trans "Trackbacks" %}
{% endif %}
{% endif %}
-{% endblock %}
+{% endblock entry-trackbacks %}
{% block entry-comments-form %}
{% if object.comments_are_open %}
{% render_comment_form for object %}
{% endif %}
-{% endblock %}
+{% endblock entry-comments-form %}
-{% endblock %}
+{% endblock content %}
-{% block admin_tools %}
+{% block admin-tools %}
{% if perms.zinnia.change_entry %}
-
@@ -225,4 +225,4 @@
{% trans "Trackbacks" %}
{% endif %}
-{% endblock %}
+{% endblock admin-tools %}
diff --git a/zinnia/templates/zinnia/entry_list.html b/zinnia/templates/zinnia/entry_list.html
index b3b7fe093..af7c3379e 100644
--- a/zinnia/templates/zinnia/entry_list.html
+++ b/zinnia/templates/zinnia/entry_list.html
@@ -1,9 +1,9 @@
{% extends "zinnia/base.html" %}
{% load i18n zinnia_tags %}
-{% block meta-description %}{% trans "Latest entries for" %} {% if category %}{% trans "the category" %} {{ category }}{% if category.description %}: {{ category.description|striptags|safe }}{% endif %}{% endif %}{% if tag %}{% trans "the tag" %} {{ tag }}{% endif %}{% if author %}{% trans "the author" %} {{ author }}{% endif %}{% endblock %}
+{% block meta-description %}{% trans "Latest entries for" %} {% if category %}{% trans "the category" %} {{ category }}{% if category.description %}: {{ category.description|striptags|safe }}{% endif %}{% endif %}{% if tag %}{% trans "the tag" %} {{ tag }}{% endif %}{% if author %}{% trans "the author" %} {{ author }}{% endif %}{% endblock meta-description %}
-{% block meta-description-page %}{% if page_obj %}{% ifnotequal page_obj.number 1 %} {% trans "page" %} {{ page_obj.number }}{% endifnotequal %}{% endif %}{% endblock %}
+{% block meta-description-page %}{% if page_obj %}{% ifnotequal page_obj.number 1 %} {% trans "page" %} {{ page_obj.number }}{% endifnotequal %}{% endif %}{% endblock meta-description-page %}
{% block link %}
{{ block.super }}
@@ -16,13 +16,13 @@
{% if author %}
{% endif %}
-{% endblock %}
+{% endblock link %}
-{% block title %}{% if category %}{% trans "Category" %} {{ category }}{% endif %}{% if tag %}{% trans "Tag" %} {{ tag }}{% endif %}{% if author %}{% trans "Author" %} {{ author }}{% endif %}{% endblock %}
+{% block title %}{% if category %}{% trans "Category" %} {{ category }}{% endif %}{% if tag %}{% trans "Tag" %} {{ tag }}{% endif %}{% if author %}{% trans "Author" %} {{ author }}{% endif %}{% endblock title %}
-{% block title-page %}{% if page_obj %}{% ifnotequal page_obj.number 1 %} - {% trans "Page" %} {{ page_obj.number }}{% endifnotequal %}{% endif %}{% endblock %}
+{% block title-page %}{% if page_obj %}{% ifnotequal page_obj.number 1 %} - {% trans "Page" %} {{ page_obj.number }}{% endifnotequal %}{% endif %}{% endblock title-page %}
-{% block body-class %}entry-list{% if page_obj %} paginated page-{{ page_obj.number }}{% endif %}{% if category %} category category-{{ category.slug }}{% endif %}{% if tag %} tag tag-{{ tag|slugify }}{% endif %}{% if author %} author author-{{ author|slugify }}{% endif %}{% endblock %}
+{% block body-class %}entry-list{% if page_obj %} paginated page-{{ page_obj.number }}{% endif %}{% if category %} category category-{{ category.slug }}{% endif %}{% if tag %} tag tag-{{ tag|slugify }}{% endif %}{% if author %} author author-{{ author|slugify }}{% endif %}{% endblock body-class %}
{% block content %}
@@ -41,7 +41,7 @@ {% blocktrans %}Tag archives: {{ tag }}{% endblocktrans %}
{% if author %}
{% blocktrans %}Author archives: {{ author }}{% endblocktrans %}
{% endif %}
-{% endblock %}
+{% endblock content-title %}
{% block content-loop %}
{% for object in object_list %}
@@ -51,20 +51,20 @@ {% blocktrans %}Author archives: {{ author }}{% endblocktrans %}
{% trans "No entries yet." %}
{% endfor %}
-{% endblock %}
+{% endblock content-loop %}
{% block content-pagination %}
{% if is_paginated %}
{% zinnia_pagination page_obj %}
{% endif %}
-{% endblock %}
+{% endblock content-pagination %}
{% block content-related %}
-{% endblock %}
+{% endblock content-related %}
-{% endblock %}
+{% endblock content %}
-{% block admin_tools %}
+{% block admin-tools %}
{% if category and perms.zinnia.change_category %}
-
@@ -86,4 +86,4 @@
{% blocktrans %}Author archives: {{ author }}{% endblocktrans %}
{% endif %}
-{% endblock %}
+{% endblock admin-tools %}
diff --git a/zinnia/templates/zinnia/entry_search.html b/zinnia/templates/zinnia/entry_search.html
index 665d47164..e86507ed2 100644
--- a/zinnia/templates/zinnia/entry_search.html
+++ b/zinnia/templates/zinnia/entry_search.html
@@ -1,16 +1,16 @@
{% extends "zinnia/entry_list.html" %}
{% load i18n zinnia_tags %}
-{% block title %}{% trans "Search results for" %} '{{ pattern }}'{% endblock %}
+{% block title %}{% trans "Search results for" %} '{{ pattern }}'{% endblock title %}
-{% block meta-description %}{% trans "Search results for" %} '{{ pattern }}'{% endblock %}
+{% block meta-description %}{% trans "Search results for" %} '{{ pattern }}'{% endblock meta-description %}
{% block link %}
{{ block.super }}
-{% endblock %}
+{% endblock link %}
-{% block body-class %}{{ block.super }} search {% if object_list %}search-results{% else %}search-no-results{% endif %}{% endblock %}
+{% block body-class %}{{ block.super }} search {% if object_list %}search-results{% else %}search-no-results{% endif %}{% endblock body-class %}
{% block content-title %}
{% trans "Search results for" %} '{{ pattern }}'
@@ -24,7 +24,7 @@ {% trans "Search results for" %} '{{ pattern }}'
{% blocktrans count entry_count=paginator.count %}{{ entry_count }} entry found{% plural %}{{ entry_count }} entries found{% endblocktrans %}
{% endif %}
-{% endblock %}
+{% endblock content-title %}
{% block content-loop %}
{% if not error %}
@@ -34,10 +34,10 @@ {% trans "Search results for" %} '{{ pattern }}'
{% trans "Nothing found." %}
{% endfor %}
{% endif %}
-{% endblock %}
+{% endblock content-loop %}
{% block content-related %}
{% include "zinnia/tags/search_form.html" %}
-{% endblock %}
+{% endblock content-related %}
diff --git a/zinnia/templates/zinnia/login.html b/zinnia/templates/zinnia/login.html
index de6929686..27f63bf56 100644
--- a/zinnia/templates/zinnia/login.html
+++ b/zinnia/templates/zinnia/login.html
@@ -1,9 +1,9 @@
{% extends "zinnia/base.html" %}
{% load i18n %}
-{% block title %}{% trans "Login required" %}{% endblock %}
+{% block title %}{% trans "Login required" %}{% endblock title %}
-{% block body-class %}login-required{% endblock %}
+{% block body-class %}login-required{% endblock body-class %}
{% block content %}
{% trans "Login required" %}
@@ -37,4 +37,4 @@ {% trans "Login required" %}
-{% endblock %}
+{% endblock content %}
diff --git a/zinnia/templates/zinnia/password.html b/zinnia/templates/zinnia/password.html
index 54996f583..013364226 100644
--- a/zinnia/templates/zinnia/password.html
+++ b/zinnia/templates/zinnia/password.html
@@ -1,9 +1,9 @@
{% extends "zinnia/base.html" %}
{% load i18n %}
-{% block title %}{% trans "Password required" %}{% endblock %}
+{% block title %}{% trans "Password required" %}{% endblock title %}
-{% block body-class %}password-required{% endblock %}
+{% block body-class %}password-required{% endblock body-class %}
{% block content %}
{% trans "Password required" %}
@@ -32,4 +32,4 @@ {% trans "Password required" %}
-{% endblock %}
+{% endblock content %}
diff --git a/zinnia/templates/zinnia/sitemap.html b/zinnia/templates/zinnia/sitemap.html
index 38aecba5a..a4bf5f116 100644
--- a/zinnia/templates/zinnia/sitemap.html
+++ b/zinnia/templates/zinnia/sitemap.html
@@ -1,9 +1,9 @@
{% extends "zinnia/base.html" %}
{% load i18n zinnia_tags mptt_tags %}
-{% block title %}{% trans "Sitemap" %}{% endblock %}
+{% block title %}{% trans "Sitemap" %}{% endblock title %}
-{% block body-class %}sitemap{% endblock %}
+{% block body-class %}sitemap{% endblock body-class %}
{% block content %}
{% trans "Sitemap" %}
@@ -69,4 +69,4 @@ {% trans "Categories" %}
{% trans "Monthly archives" %}
{% get_archives_entries %}
-{% endblock %}
+{% endblock content %}
diff --git a/zinnia/templates/zinnia/skeleton.html b/zinnia/templates/zinnia/skeleton.html
index 1bfcc7bd6..548d4ecff 100644
--- a/zinnia/templates/zinnia/skeleton.html
+++ b/zinnia/templates/zinnia/skeleton.html
@@ -2,16 +2,16 @@
- Zinnia's Weblog - {% block title %}{% endblock %}{% block title-page %}{% endblock %}
+ Zinnia's Weblog - {% block title %}{% endblock title %}{% block title-page %}{% endblock title-page %}
-
-
+
+
- {% block meta %}{% endblock %}
+ {% block meta %}{% endblock meta %}
@@ -20,10 +20,10 @@
- {% block link %}{% endblock %}
- {% block script %}{% endblock %}
+ {% block link %}{% endblock link %}
+ {% block script %}{% endblock script %}
-
+
- {% block slider %}{% endblock %}
+ {% block slider %}{% endblock slider %}
{% block content %}
@@ -76,11 +76,11 @@
{% trans "Useful links" %}
{% trans "Search" %}
{% include "zinnia/tags/search_form.html" %}
- {% endblock %}
+ {% endblock content %}
{% trans "Comments" %}
{% endif %} {% endif %}