From 4203b8c0eaeb722f0ffe9d0b82b907aace2a43cf Mon Sep 17 00:00:00 2001 From: Michael Tremer Date: Thu, 23 Jan 2020 12:25:40 +0000 Subject: [PATCH] blog: Add meta tags for OpenGraph & Twitter Those tags will be read by Facebook, Twitter and other software like Discourse to show a short summary about the content behind the link. Signed-off-by: Michael Tremer --- src/templates/blog/base.html | 1 + src/templates/blog/post.html | 30 ++++++++++++++++++++++++++++++ 2 files changed, 31 insertions(+) diff --git a/src/templates/blog/base.html b/src/templates/blog/base.html index d06dbf3a..723d7024 100644 --- a/src/templates/blog/base.html +++ b/src/templates/blog/base.html @@ -2,6 +2,7 @@ {% block head %} + {% block meta %}{% end block %} {% end block %} {% block content %} diff --git a/src/templates/blog/post.html b/src/templates/blog/post.html index 4532880e..54a3eb78 100644 --- a/src/templates/blog/post.html +++ b/src/templates/blog/post.html @@ -2,6 +2,36 @@ {% block title %}{{ post.title }}{% end block %} +{% block meta %} + {% import ipfire.accounts as accounts %} + + + + + + + + + + + + {% if isinstance(post.author, accounts.Account) %} + + + + {% end %} + {% for tag in post.tags %} + + {% end %} + + + + + + + +{% end block %} + {% block main %}
-- 2.47.3