[bug fix] thumbnail refer to incorrect image url when site is put in a subdirectory
In hexo 3.2.0, the implementation of url_for() has been changed.
This commit is contained in:
parent
88fbc01466
commit
f8430c10b0
|
@ -1,8 +1,8 @@
|
|||
<a href="<%- url_for((post.link ? post.link : post.path)) %>" class="thumbnail">
|
||||
<% var thumbnailUrl = thumbnail(post) %>
|
||||
<% if (thumbnailUrl) { %>
|
||||
<span style="background-image:url(<%- url_for(thumbnailUrl) %>)" alt="<%= post.title %>" class="thumbnail-image"></span>
|
||||
<span style="background-image:url(<%= thumbnailUrl %>)" alt="<%= post.title %>" class="thumbnail-image"></span>
|
||||
<% } else { %>
|
||||
<span class="thumbnail-image thumbnail-none"></span>
|
||||
<% } %>
|
||||
</a>
|
||||
</a>
|
||||
|
|
Loading…
Reference in New Issue