Skip to content

Commit

Permalink
fix related_posts
Browse files Browse the repository at this point in the history
  • Loading branch information
xaoxuu committed Mar 9, 2021
1 parent 5bb64e5 commit ace3bc3
Showing 1 changed file with 16 additions and 5 deletions.
21 changes: 16 additions & 5 deletions layout/_partial/main/article/related_posts.ejs
Original file line number Diff line number Diff line change
@@ -1,5 +1,16 @@
<div class='related-wrap' id='related-posts'><%-
popular_posts_wrapper({
title: __('meta.related_posts'),
json: popular_posts_json({ maxCount: 5 , ulClass: 'related-posts' , PPMixingRate: 0.2 , isImage: true , isExcerpt: true} , page )
}) %></div>
<%
function layoutDiv() {
if (theme.article.related_posts.enable) {
var el = '';
el += '<div class="related-wrap" id="related-posts">';
el += popular_posts_wrapper({
title: __('meta.related_posts'),
json: popular_posts_json({ maxCount: 5 , ulClass: 'related-posts' , PPMixingRate: 0.2 , isImage: true , isExcerpt: true} , page )
});
el += '</div>';
return el;
}
return;
}
%>
<%- layoutDiv() %>

0 comments on commit ace3bc3

Please sign in to comment.