[gimp-web/testing] Monkeying with microdata/metadata
- From: Pat David <patdavid src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gimp-web/testing] Monkeying with microdata/metadata
- Date: Thu, 14 Jan 2016 20:45:57 +0000 (UTC)
commit cb3eeda2e3c4af21645d186407999a4f814c94f0
Author: Pat David <patdavid gmail com>
Date: Thu Jan 14 14:45:47 2016 -0600
Monkeying with microdata/metadata
themes/newgimp/templates/article.html | 4 ++--
themes/newgimp/templates/page.html | 8 ++++++++
2 files changed, 10 insertions(+), 2 deletions(-)
---
diff --git a/themes/newgimp/templates/article.html b/themes/newgimp/templates/article.html
index 716e469..3fe1f3e 100644
--- a/themes/newgimp/templates/article.html
+++ b/themes/newgimp/templates/article.html
@@ -39,8 +39,8 @@
{% endif %}
{% if article.summary %}
- <meta itemprop='description' content='{{ article.summary }}' />
- <meta property='og:description' content='{{ article.summary }}' />
+ <meta itemprop='description' content="{{ article.summary|striptags }}" />
+ <meta property='og:description' content="{{ article.summary|striptags }}" />
{% endif %}
diff --git a/themes/newgimp/templates/page.html b/themes/newgimp/templates/page.html
index fd4d2dd..ea2735a 100644
--- a/themes/newgimp/templates/page.html
+++ b/themes/newgimp/templates/page.html
@@ -22,6 +22,14 @@
{% endfor %}
{% endif %}
+ {% if page.summary %}
+ <meta itemprop='description' content="{{ page.summary|striptags }}" />
+ <meta property='og:description' content="{{ page.summary|striptags }}" />
+ {% else %}
+ <meta itemprop='description' content="{{ page.content|striptags|truncate() }}" />
+ <meta property='og:description' content="{{ page.content|striptags|truncate() }}" />
+ {% endif %}
+
{% endblock head %}
{% block content %}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]