Apply feedback from issue discussion - remove config option and simplify change

This commit is contained in:
olipratt 2017-03-04 12:49:16 +00:00
parent 0931d35525
commit 6576ab0e80
3 changed files with 6 additions and 4 deletions

View file

@ -40,7 +40,11 @@
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
<meta name="HandheldFriendly" content="True" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<meta name="robots" content="{{ ROBOTS_HIDDEN if (ROBOTS_HIDDEN and page in hidden_pages) else ROBOTS }}" />
{% if page in hidden_pages %}
<meta name="robots" content="noindex, nofollow" />
{% else %}
<meta name="robots" content="{{ ROBOTS }}" />
{% endif %}
{% if BROWSER_COLOR %}
<!-- Chrome, Firefox OS and Opera -->

View file

@ -5,4 +5,4 @@ Status: hidden
This is a hidden page.
It will have the contents of `ROBOTS_HIDDEN` as the value of the `robots` `<meta>` tag.
It will have `noindex, nofollow` as the value of the `robots` `<meta>` tag.

View file

@ -18,9 +18,7 @@ SITELOGO = u'https://www.example.com/img/profile.png'
FAVICON = SITEURL + '/images/favicon.ico'
BROWSER_COLOR = '#333'
# 'robots' meta tag values for normal and hidden pages.
ROBOTS = u'index, follow'
ROBOTS_HIDDEN = u'noindex, nofollow'
THEME = u'../'
PATH = u'content'