Mercurial > p > roundup > code
diff website/www/_templates/layout.html @ 6666:54af7ce65e6e
Add canonical url link in header
Add canonical url to all pages. Requires upgrade to at least 1.8.0 of
sphinx. Upgraded virualenv on sourceforge to have sphinx 1.8.5 to
allow it to work. Hand patched the files on sourceforge and deployed.
Also added a postprocess step to Makefile needed on sourceforge to
load searchtools.js.
| author | John Rouillard <rouilj@ieee.org> |
|---|---|
| date | Mon, 09 May 2022 19:57:16 -0400 |
| parents | 2aa045e06fff |
| children | c574d888dd87 |
line wrap: on
line diff
--- a/website/www/_templates/layout.html Wed May 04 15:28:30 2022 -0400 +++ b/website/www/_templates/layout.html Mon May 09 19:57:16 2022 -0400 @@ -34,6 +34,9 @@ {%- for scriptfile in script_files %} <script type="text/javascript" src="{{ pathto(scriptfile, 1) }}"></script> {%- endfor %} + {%- if pageurl %} + <link rel="canonical" href="{{ pageurl|e }}" /> + {%- endif %} {%- if use_opensearch %} <link rel="search" type="application/opensearchdescription+xml" title="{% trans docstitle=docstitle|e %}Search within {{ docstitle }}{% endtrans %}"
