-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy patharchive.html
36 lines (35 loc) · 1.45 KB
/
archive.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
---
layout: default
description: 首页
keywords: webcraft,github,jekyll,ruby,css,javascript,index
---
<div class="content-cnt clearfix" id="articles-list">
<section id="articles-list-body">
{% capture post_year_now %}{{ site.time | date: '%Y' }}{% endcapture %}
{% capture per_year_articles_id %}per-year-articles-{{ post_year_now }}{% endcapture %}
<div class="per-year-articles" id="{{ per_year_articles_id }}">
<h3 class="which-year">{{ post_year_now }}</h3>
{% for post in site.categories.articles %}
{% capture post_year_article %}{{ post.date | date: '%Y' }}{% endcapture %}
{% if post_year_now != post_year_article %}
{% assign post_year_now = post_year_article %}
</div>
{% capture per_year_articles_id %}per-year-articles-{{ post_year_now }}{% endcapture %}
<div class="per-year-articles none" id="{{ per_year_articles_id }}">
<h3 class="which-year">{{ post_year_now }}</h3>
{% endif %}
<article>
<div class="article-head">
<h3><a href="{{ post.url }}">{{ post.title }}</a></h3>
<div class="clearfix">
<div class="article-post-time">
<span>‣</span>
<time pubdate="{{ post.date | date: '%b %d, %Y' }}">{{ post.date | date: '%b %d' }}</time>
</div>
</div>
</div>
</article>
{% endfor %}
</div>
</section>
</div>