Mercurial > web-octave
diff _includes/head.html @ 57:002d154531d4 kai
Added MathJax. Use absolute_url and relative_url insted of prepend.
author | Kai T. Ohlhus <k.ohlhus@gmail.com> |
---|---|
date | Tue, 11 Oct 2016 15:57:58 +0200 |
parents | 6b221a8157ab |
children | eed30c5acfbe |
line wrap: on
line diff
--- a/_includes/head.html Tue Oct 11 15:55:32 2016 +0200 +++ b/_includes/head.html Tue Oct 11 15:57:58 2016 +0200 @@ -3,11 +3,21 @@ <meta http-equiv="X-UA-Compatible" content="IE=edge"> <meta name="viewport" content="width=device-width, initial-scale=1"> - <title>{% if page.title %}{{ site.title }} :: {{ page.title }}{% else %}{{ site.title }}{% endif %}</title> + <title>{{ site.title }}{% if page.title %} :: {{ page.title }}{% endif %}</title> <meta name="description" content="{% if page.excerpt %}{{ page.excerpt | strip_html | strip_newlines | truncate: 160 }}{% else %}{{ site.description }}{% endif %}"> - <link rel="stylesheet" href="{{ "/css/octave.css" | prepend: site.baseurl }}"> + <link rel="stylesheet" href="{{ "/css/octave.css" | relative_url }}"> + + <link rel="canonical" href="{{ page.url | replace:'index.html','' | absolute_url }}"> + <link rel="alternate" type="application/rss+xml" title="{{ site.title }}" href="{{ "/feed.xml" | relative_url }}"> - <link rel="canonical" href="{{ page.url | replace:'index.html','' | prepend: site.baseurl | prepend: site.url }}"> - <link rel="alternate" type="application/rss+xml" title="{{ site.title }}" href="{{ "/feed.xml" | prepend: site.baseurl }}"> + <script type="text/x-mathjax-config"> + MathJax.Hub.Config({ + tex2jax: { inlineMath: [['$','$'], ['\\(','\\)']] }, + TeX: { equationNumbers: { autoNumber: 'all' } } + }); + </script> + <script type="text/javascript" async + src="https://cdn.mathjax.org/mathjax/latest/MathJax.js?config=TeX-MML-AM_CHTML"> + </script> </head>