[tor-commits] [tpo/master] Add metatags
hiro at torproject.org
hiro at torproject.org
Mon Mar 25 16:56:47 UTC 2019
commit 640815f46b8dad323c4818e7fc2ce0188625a8e3
Author: hiro <hiro at torproject.org>
Date: Mon Mar 25 17:56:23 2019 +0100
Add metatags
---
templates/about.html | 8 +-------
templates/homepage.html | 9 +--------
templates/layout.html | 9 +--------
templates/meta.html | 16 ++++++++++++++++
4 files changed, 19 insertions(+), 23 deletions(-)
diff --git a/templates/about.html b/templates/about.html
index 4372ae2..8a6552c 100644
--- a/templates/about.html
+++ b/templates/about.html
@@ -1,10 +1,4 @@
-<!doctype html>
-<meta charset="utf-8">
-<meta name="viewport" content="width=device-width, initial-scale=1">
-<link rel="stylesheet" href="{{ '/static/bootstrap.css'|asseturl }}">
-<link rel="stylesheet" href="{{ '/static/fonts/open-iconic/font/css/open-iconic-bootstrap.css'|asseturl }}">
-<link rel="stylesheet" href="{{ '/static/fonts/fontawesome/css/all.min.css'|asseturl }}" rel="stylesheet">
-<title>{{ _("Tor Project") }} | {% block title %}{{ this.title }}{% endblock %}</title>
+{% include 'meta.html' %}
<body class="no-gutters">
<header>
{% include 'navbar.html' %}
diff --git a/templates/homepage.html b/templates/homepage.html
index c1f4d2a..25ba0ba 100644
--- a/templates/homepage.html
+++ b/templates/homepage.html
@@ -1,11 +1,4 @@
-<!doctype html>
-<meta charset="utf-8">
-<meta name="viewport" content="width=device-width, initial-scale=1">
-<link rel="stylesheet" href="{{ '/static/bootstrap.css'|asseturl }}">
-<link rel="stylesheet" href="{{ '/static/fonts/open-iconic/font/css/open-iconic-bootstrap.css'|asseturl }}">
-<link rel="stylesheet" href="{{ '/static/fonts/fontawesome/css/all.min.css'|asseturl }}" rel="stylesheet">
-
-<title>{{ _("Tor Project") }} | {% block title %}{{ this.title }}{% endblock %}</title>
+{% include 'meta.html' %}
<body class="no-gutters">
<header>
{% include 'navbar.html' %}
diff --git a/templates/layout.html b/templates/layout.html
index d7bfa42..db1168f 100644
--- a/templates/layout.html
+++ b/templates/layout.html
@@ -1,11 +1,4 @@
-<!doctype html>
-<html xmlns="http://www.w3.org/1999/xhtml" {% if bag('alternatives', this.alt, 'direction') == 'text-right' %}dir="rtl"{% endif %}>
-<meta charset="utf-8">
-<meta name="viewport" content="width=device-width, initial-scale=1">
-<link rel="stylesheet" href="{{ '/static/bootstrap.css'|asseturl }}">
-<link rel="stylesheet" href="{{ '/static/fonts/open-iconic/font/css/open-iconic-bootstrap.css'|asseturl }}">
-<link rel="stylesheet" href="{{ '/static/fonts/fontawesome/css/all.min.css'|asseturl }}" rel="stylesheet">
-<title>{{ _("Tor Project") }} | {% block title %}{{ this.title }}{% endblock %}</title>
+{% include 'meta.html' %}
<body class="no-gutters">
<header>
{% include 'navbar.html' %}
diff --git a/templates/meta.html b/templates/meta.html
new file mode 100644
index 0000000..714897e
--- /dev/null
+++ b/templates/meta.html
@@ -0,0 +1,16 @@
+<!doctype html>
+<html xmlns="http://www.w3.org/1999/xhtml" {% if bag('alternatives', this.alt, 'direction') == 'text-right' %}dir="rtl"{% endif %}>
+<meta charset="utf-8">
+<meta name="viewport" content="width=device-width, initial-scale=1">
+<meta name="description" content="Defend yourself against tracking and surveillance. Circumvent censorship.">
+<meta name="twitter:card" content="summary" />
+<meta name="twitter:site" content="@torproject" />
+<meta name="twitter:creator" content="@torproject" />
+<meta property="og:url" content="https://torproject.org" />
+<meta property="og:title" content="The Tor Project | Privacy & Freedom Online" />
+<meta property="og:description" content="Defend yourself against tracking and surveillance. Circumvent censorship." />
+<meta property="og:image" content="" />
+<link rel="stylesheet" href="{{ '/static/bootstrap.css'|asseturl }}">
+<link rel="stylesheet" href="{{ '/static/fonts/open-iconic/font/css/open-iconic-bootstrap.css'|asseturl }}">
+<link rel="stylesheet" href="{{ '/static/fonts/fontawesome/css/all.min.css'|asseturl }}" rel="stylesheet">
+<title>{{ _("Tor Project") }} | {% block title %}{{ this.title }}{% endblock %}</title>
More information about the tor-commits
mailing list