diff options
| author | Eltrac Koalar <hi@guhub.cn> | 2022-08-21 21:37:55 +0800 |
|---|---|---|
| committer | Eltrac Koalar <hi@guhub.cn> | 2022-08-21 21:37:55 +0800 |
| commit | 5977636a5fc5b4fed253b4138b3f2d83377e6457 (patch) | |
| tree | 5b79a1c09ab3028daf16a774a922939fe69a01e8 /includes | |
| parent | 8c76f980f0f8bf169de18b32fa863fd294ff7ec2 (diff) | |
:apple: Add: 将「更人性化的时间」运用在文章时间显示上
Diffstat (limited to 'includes')
| -rw-r--r-- | includes/post-list.php | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/includes/post-list.php b/includes/post-list.php index 28259b9..6d0636c 100644 --- a/includes/post-list.php +++ b/includes/post-list.php @@ -1,11 +1,17 @@ <?php if (!defined('__TYPECHO_ROOT_DIR__')) exit; ?> <div class="col-12" id="main" role="main"> + <?php if($this->is('archive')) { ?><h3 class="archive-title"><?php $this->archiveTitle(array( + 'category' => _t('分类 %s 下的文章'), + 'search' => _t('包含关键字 %s 的文章'), + 'tag' => _t('标签 %s 下的文章'), + 'author' => _t('%s 发布的文章') + ), '', ''); ?></h3><?php } ?> <!-- 文章列表 --> <?php while($this->next()): ?> <article class="post post-atmain" itemscope itemtype="http://schema.org/BlogPosting"> <h2 class="post-title" itemprop="name headline"><a itemprop="url" href="<?php $this->permalink() ?>"><?php $this->title() ?></a></h2> <ul class="post-meta"> - <li><time datetime="<?php $this->date('c'); ?>" itemprop="datePublished"><?php $this->date(); ?></time></li> + <li><time datetime="<?php $this->date('c'); ?>" itemprop="datePublished"><?php echo Matcha::date($this->created); ?></time></li> <li><?php $this->category(','); ?></li> <li itemprop="interactionCount"><a href="<?php $this->permalink() ?>#comments"><?php $this->commentsNum('0 评论', '1 评论', '%d 评论'); ?></a></li> </ul> |
