From 8da4fc750363400e330b82c6806eb341fc5ae92c Mon Sep 17 00:00:00 2001 From: RealOrangeOne Date: Sun, 26 Jun 2016 11:57:22 +0100 Subject: [PATCH] add description content to category pages --- pelicanconf.py | 4 +++- theme/templates/category.html | 11 +++++++++-- 2 files changed, 12 insertions(+), 3 deletions(-) diff --git a/pelicanconf.py b/pelicanconf.py index 71e4b86..87b84b8 100644 --- a/pelicanconf.py +++ b/pelicanconf.py @@ -54,12 +54,14 @@ FEED_DOMAIN = SITEURL # Setup plugins PLUGIN_PATHS = ["pelican_plugins", "plugins"] -PLUGINS = ["sitemap", "filetime_from_git", "pelican-jinja2content", "open_graph"] +PLUGINS = ["sitemap", "filetime_from_git", "pelican-jinja2content", "open_graph", "autopages"] SITEMAP = { "format": "xml" } +CATEGORY_PAGE_PATH = "theme/templates/categories" + # Setup markdown extensions from fontawesome_markdown import FontAwesomeExtension from pyembed.markdown import PyEmbedMarkdown diff --git a/theme/templates/category.html b/theme/templates/category.html index 188d2e2..463affd 100644 --- a/theme/templates/category.html +++ b/theme/templates/category.html @@ -15,12 +15,19 @@
-

{{ category|title }}

+

{{ category.name|title }}


+ {% if category.page %} +
+
+ {{ category.page.content }} +
+
+ {% endif %}
@@ -33,7 +40,7 @@ {{ article.title }}
- {{ article.title }} + {{ article.summary|striptags|e }}