Make article:author OpenGraph compatible

OpenGraph actually needs a profile URL as value to article:author.
We point it to the author's page and adjust the OG meta tags on
author.html to include the relevant profile information.
This commit is contained in:
Mr. Senko
2016-03-31 23:55:19 +03:00
parent 911b8ec25c
commit 5a83a4575d
3 changed files with 10 additions and 3 deletions

View File

@ -2,6 +2,15 @@
{% block title %}{{ SITENAME }} - Articles by {{ author }}{% endblock %}
{% block opengraph %}
{{ super() }}
<meta property="og:title" content="{{ SITENAME }} - Articles by {{ author }}">
<meta property="og:type" content="profile">
<meta property="profile:first_name" content="{{ author.name.split(' ')[0] }}">
<meta property="profile:last_name" content="{{ author.name.split(' ')[1:]|join(' ') }}">
<meta property="profile:username" content="{{ author.slug }}">
{% endblock opengraph %}
{% block header %}
<!-- Page Header -->
{% if HEADER_COVER %}