Skip to content

Commit 1bb985b

Browse files
committed
优化底部信息
1 parent 39ae055 commit 1bb985b

File tree

1 file changed

+11
-12
lines changed

1 file changed

+11
-12
lines changed

templates/footer.html

Lines changed: 11 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,20 +1,19 @@
1-
Copyright © <span id="year"></span> <a href="{{ blogBase['homeUrl'] }}">{{ blogBase['title'] }}</a>
2-
<p>
3-
{%- if blogBase['filingNum']!='' -%}
4-
<a href="https://beian.miit.gov.cn/" target="_blank">{{ blogBase['filingNum'] }}</a>
5-
{%- endif %}
6-
<span id="runday"></span>Powered by <a href="https://meekdai.com/Gmeek.html" target="_blank">Gmeek</a>
7-
</p>
1+
<div id="footer1">Copyright © <span id="copyrightYear"></span> <a href="{{ blogBase['homeUrl'] }}">{{ blogBase['title'] }}</a></div>
2+
<div id="footer2">
3+
{%- if blogBase['filingNum']!='' -%}
4+
<span id="filingNum"><a href="https://beian.miit.gov.cn/" target="_blank">{{ blogBase['filingNum'] }}</a></span>
5+
{%- endif %}
6+
<span id="runday"></span>Powered by <a href="https://meekdai.com/Gmeek.html" target="_blank">Gmeek</a>
7+
</div>
88

99
<script>
10+
var now=new Date();
11+
document.getElementById("copyrightYear").innerHTML=now.getFullYear();
12+
1013
if("{{ blogBase['startSite'] }}"!=""){
11-
var now=new Date();
1214
var startSite=new Date("{{ blogBase['startSite'] }}");
1315
var diff=now.getTime()-startSite.getTime();
1416
var diffDay=Math.floor(diff/(1000*60*60*24));
15-
document.getElementById("year").innerHTML=now.getFullYear();
16-
if("{{ blogBase['filingNum'] }}"!=""){document.getElementById("runday").innerHTML=" • "+"{{ i18n['run'] }}"+diffDay+"{{ i18n['days'] }}"+" • ";}
17-
else{document.getElementById("runday").innerHTML="{{ i18n['run'] }}"+diffDay+"{{ i18n['days'] }}"+" • ";}
17+
document.getElementById("runday").innerHTML="{{ i18n['run'] }}"+diffDay+"{{ i18n['days'] }}"+" • ";
1818
}
1919
</script>
20-

0 commit comments

Comments
 (0)