Added a post.date condition in date.ejs
Signed-off-by: Xiaofeng QU <xiaofeng.qu.hk@ieee.org>pull/29/head
parent
9396bc1994
commit
43a209bbd4
|
@ -7,7 +7,7 @@
|
|||
<% if (post.link || post.title){ %>
|
||||
<header class="article-header">
|
||||
<%- partial('post/title', {class_name: 'article-title'}) %>
|
||||
<div class="article-meta">
|
||||
<div class="article-meta">
|
||||
<%- partial('post/date', {class_name: 'article-date', date_format: null}) %>
|
||||
<%- partial('post/category') %>
|
||||
</div>
|
||||
|
|
|
@ -1,6 +1,8 @@
|
|||
<div class="<%= class_name %>">
|
||||
<i class="fa fa-calendar"></i>
|
||||
<a href="<%- url_for(post.path) %>">
|
||||
<time datetime="<%= date_xml(post.date) %>" itemprop="datePublished"><%= date(post.date, date_format) %></time>
|
||||
</a>
|
||||
</div>
|
||||
<% if (post.date){ %>
|
||||
<div class="<%= class_name %>">
|
||||
<i class="fa fa-calendar"></i>
|
||||
<a href="<%- url_for(post.path) %>">
|
||||
<time datetime="<%= date_xml(post.date) %>" itemprop="datePublished"><%= date(post.date, date_format) %></time>
|
||||
</a>
|
||||
</div>
|
||||
<% } %>
|
Loading…
Reference in New Issue