Skip to content

Commit

Permalink
add: “since" year in footer
Browse files Browse the repository at this point in the history
  • Loading branch information
MOxFIVE committed Apr 23, 2016
1 parent 22f50c9 commit 5b8b956
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
3 changes: 3 additions & 0 deletions _config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,9 @@ favicon: /favicon.png
## https://hexo.io/docs/configuration.html#URL
root_url:

# Year of Site Creation | 网站成立年份
since: 2016

# Social info. Bar | 社交信息展示
## Keep "mailto:" in Email | 设置 Email 时保留 "mailto:"
## Encrypt email 加密邮件地址 http://ctrlq.org/encode/
Expand Down
3 changes: 2 additions & 1 deletion layout/_partial/footer.ejs
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,8 @@
<div class="outer">
<div id="footer-info">
<div class="footer-left">
<i class="fa fa-copyright"></i> <%= date(new Date(), 'YYYY') %> <%= config.author || config.title %>
<i class="fa fa-copyright"></i>
<% if (theme.since && !isNaN(theme.since) && theme.since < date(new Date(), 'YYYY')) { %><%- theme.since%>-<% } %><%= date(new Date(), 'YYYY') %> <%= config.author || config.title %>
</div>
<div class="footer-right">
<a href="http://hexo.io/" target="_blank" title="<%= __('tooltip.Hexo') %>">Hexo</a> Theme <a href="https://github.com/MOxFIVE/hexo-theme-yelee" target="_blank" title="<%= __('tooltip.Yelee') %>">Yelee</a> by MOxFIVE <i class="fa fa-heart animated infinite pulse"></i>
Expand Down

0 comments on commit 5b8b956

Please sign in to comment.