Skip to content

Commit

Permalink
update sitemap.py and update mongodb/layout.html and manual/page.html…
Browse files Browse the repository at this point in the history
… for meta description and version instead of release
  • Loading branch information
kay-kim committed Aug 8, 2015
1 parent 7c85047 commit 54e72d3
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 6 deletions.
7 changes: 2 additions & 5 deletions bin/sitemap_gen.py
Original file line number Diff line number Diff line change
Expand Up @@ -132,11 +132,8 @@
SITEMAP_HEADER = \
'<?xml version="1.0" encoding="UTF-8"?>\n' \
'<urlset\n' \
' xmlns="http://www.google.com/schemas/sitemap/0.84"\n' \
' xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"\n' \
' xsi:schemaLocation="http://www.google.com/schemas/sitemap/0.84\n' \
' http://www.google.com/schemas/sitemap/0.84/' \
'sitemap.xsd">\n'
' xmlns="http://www.google.com/schemas/sitemap/0.9"\n' \
'>\n'
SITEMAP_FOOTER = '</urlset>\n'
SITEURL_XML_PREFIX = ' <url>\n'
SITEURL_XML_SUFFIX = ' </url>\n'
Expand Down
6 changes: 5 additions & 1 deletion themes/manual/page.html
Original file line number Diff line number Diff line change
Expand Up @@ -2,14 +2,18 @@

{%- block htmltitle %}
{%- if not embedded and docstitle %}
{%- set titlesuffix = " &mdash; "|safe + docstitle|e + " " + release|e %}
{%- set titlesuffix = " &mdash; "|safe + docstitle|e + " " + version|e %}
{%- else %}
{%- set titlesuffix = "" %}
{%- endif -%}

<title>{{ title|striptags|e }}{{ titlesuffix }}</title>
{%- endblock -%}

{%- block metadescription %}
<meta name="description" content="MongoDB Manual {{version}} {{title}}"/>
{%- endblock -%}

{%- block canonicalref %}
{%- if pagename == 'index' %}
<link rel="canonical" href="http://docs.mongodb.org/{{theme_project}}/" />
Expand Down
3 changes: 3 additions & 0 deletions themes/mongodb/layout.html
Original file line number Diff line number Diff line change
Expand Up @@ -111,8 +111,11 @@
<meta http-equiv="Content-Type" content="text/html; charset={{ encoding }}" />
<meta name="robots" content="index" />
<meta name="release" content="{{release}}"/>
<meta name="version" content="{{version}}"/>
<meta name="DC.Source" content="https://github.com/mongodb/{{theme_repo_name}}/blob/{{theme_branch}}/source/{{pagename}}.txt"/>

{%- block metadescription %}{%- endblock -%}

{%- block canonicalref %}{%- endblock -%}

{{ metatags }}
Expand Down

0 comments on commit 54e72d3

Please sign in to comment.