Browse Source

Add meta robots tag to pages

Default is "index,follow" but we turn off indexing of tags, categories,
archives, etc.
restyle-spring-2019
Annika Backstrom 11 months ago
parent
commit
7b9ad1fee8

+ 4
- 0
themes/histrionic/templates/archives.html View File

@@ -1,5 +1,9 @@
1 1
 {% extends "base.html" %}
2 2
 
3
+{% block metarobots %}
4
+  <meta name="robots" value="noindex,follow">
5
+{% endblock %}
6
+
3 7
 {% block content %}
4 8
   <div class="row">
5 9
     <div class="cute-12-tablet">

+ 4
- 0
themes/histrionic/templates/base.html View File

@@ -15,6 +15,10 @@
15 15
     {% block scripts %}
16 16
     {% endblock %}
17 17
 
18
+    {% block metarobots %}
19
+      <meta name="robots" value="index,follow">
20
+    {% endblock %}
21
+
18 22
     {% if FEED_ALL_ATOM %}
19 23
     <link href="{{ FEED_DOMAIN }}/{{ FEED_ALL_ATOM }}" type="application/atom+xml" rel="alternate" title="{{ SITENAME }} Atom Feed" />
20 24
     {% endif %}

+ 5
- 0
themes/histrionic/templates/category.html View File

@@ -1,6 +1,11 @@
1 1
 {% extends "base.html" %}
2
+
2 3
 {% block title %}{{ category }} - {{ SITENAME }}{% endblock %}
3 4
 
5
+{% block metarobots %}
6
+  <meta name="robots" value="noindex,follow">
7
+{% endblock %}
8
+
4 9
 {% block content %}
5 10
 
6 11
 <h1>Posts categorized under: {{ category }}</h1>

+ 4
- 0
themes/histrionic/templates/index.html View File

@@ -1,5 +1,9 @@
1 1
 {% extends "base.html" %}
2 2
 
3
+{% block metarobots %}
4
+  <meta name="robots" value="noindex,follow">
5
+{% endblock %}
6
+
3 7
 {% block body_classes %}archive{% endblock %}
4 8
 
5 9
 {% block content %}

+ 6
- 1
themes/histrionic/templates/tag.html View File

@@ -1,6 +1,11 @@
1 1
 {% extends "base.html" %}
2
+
2 3
 {% block title %}{{ tag }} - {{ SITENAME }}{% endblock %}
3 4
 
5
+{% block metarobots %}
6
+  <meta name="robots" value="noindex,follow">
7
+{% endblock %}
8
+
4 9
 {% block content %}
5 10
 
6 11
 <h1>Post tagged: {{ tag }}</h1>
@@ -11,4 +16,4 @@
11 16
 
12 17
 {% include 'pagination.inc.html' %}
13 18
 
14
-{% endblock %}
19
+{% endblock %}

+ 6
- 1
themes/histrionic/templates/tags.html View File

@@ -1,10 +1,15 @@
1 1
 {% extends "base.html" %}
2
+
2 3
 {% block title %}{{ SITENAME }}{% endblock %}
3 4
 
5
+{% block metarobots %}
6
+  <meta name="robots" value="noindex,follow">
7
+{% endblock %}
8
+
4 9
 {% block content %}
5 10
 
6 11
 <h1>Tags</h1>
7
-	
12
+
8 13
 <ul class="tagcloud">
9 14
   {% for tag in tag_cloud %}
10 15
     <li class="tag-{{ tag.1 }}"><a href="{{ SITEURL }}/{{ tag.0.url }}">{{ tag.0 }}</a></li>

Loading…
Cancel
Save