mirror of
https://github.com/next-theme/hexo-theme-next.git
synced 2026-01-17 18:22:33 +00:00
Escape page metadata in post template (#884)
This commit is contained in:
parent
13cc3171de
commit
ae14cd177c
@ -19,8 +19,8 @@
|
||||
</span>
|
||||
|
||||
<span hidden itemprop="post" itemscope itemtype="http://schema.org/CreativeWork">
|
||||
<meta itemprop="name" content="{{ page.title + ' | ' + title }}">
|
||||
<meta itemprop="description" content="{{ page.description }}">
|
||||
<meta itemprop="name" content="{{ escape_html(page.title or '') + ' | ' + title }}">
|
||||
<meta itemprop="description" content="{{ escape_html(page.description or '') }}">
|
||||
</span>
|
||||
|
||||
{%- if post.header !== false %}
|
||||
@ -134,14 +134,14 @@
|
||||
<div class="post-nav">
|
||||
<div class="post-nav-item">
|
||||
{%- if prev %}
|
||||
<a href="{{ url_for(prev.path) }}" rel="prev" title="{{ prev.title }}">
|
||||
<a href="{{ url_for(prev.path) }}" rel="prev" title="{{ escape_html(prev.title or '') }}">
|
||||
<i class="fa fa-angle-left"></i> {{ prev.title }}
|
||||
</a>
|
||||
{%- endif %}
|
||||
</div>
|
||||
<div class="post-nav-item">
|
||||
{%- if next %}
|
||||
<a href="{{ url_for(next.path) }}" rel="next" title="{{ next.title }}">
|
||||
<a href="{{ url_for(next.path) }}" rel="next" title="{{ escape_html(next.title or '') }}">
|
||||
{{ next.title }} <i class="fa fa-angle-right"></i>
|
||||
</a>
|
||||
{%- endif %}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user