From bb994cb94b77daf3e04f2ba329b70ad394b562f2 Mon Sep 17 00:00:00 2001 From: Arul Date: Thu, 15 Sep 2016 11:31:46 +0530 Subject: [PATCH] Author bio in article page MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - Example conf in pelicanconf.py AUTHORS_BIO = { "arul": { "name": "Arulraj V", "cover": "https://www.gravatar.com/avatar/dead1c3ffb26a27d8b5e30e1c30e46e6?s=600", "image": "https://www.gravatar.com/avatar/dead1c3ffb26a27d8b5e30e1c30e46e6?s=600", "website": "http://arulraj.net", "location": "Chennai", "bio": "• Architect • DevOps • Full Stack Developer • Aspiring Entrepreneur •", "twitter": "arulrajnet", "facebook": "arulraj.net" } } --- templates/article.html | 31 ++++++++++++++++++++++++++++++- 1 file changed, 30 insertions(+), 1 deletion(-) diff --git a/templates/article.html b/templates/article.html index 4e40290..153ce5d 100644 --- a/templates/article.html +++ b/templates/article.html @@ -170,7 +170,36 @@
- + {% for author in article.authors %} + {% if AUTHORS_BIO and AUTHORS_BIO[author.name.lower()] != None %} + + {% endif %} + {% endfor %}