mirror of
https://github.com/jkjoy/Typecho-Theme-Puock.git
synced 2026-06-17 16:14:12 +00:00
1.1.3
- 兼容typecho 1.3.0版本
- 修复pjax黑暗模式下闪烁问题
- 修复说说页面的pjax加载问题
- 修复上一篇与下一篇文章的链接
- 增加归属地显示设置
- 增加系统显示设置
- 增加浏览器信息显示设置
- 修复pjax模式下的404跳转
This commit is contained in:
+9
-17
@@ -15,32 +15,28 @@ if (!defined('__TYPECHO_ROOT_DIR__')) exit; ?>
|
||||
</nav>
|
||||
</div>
|
||||
<div id="page-archives">
|
||||
<div id="page" class="w-100">
|
||||
<div id="posts" class="animated fadeInLeft ">
|
||||
<div class="p-block puock-text">
|
||||
<div class="timeline no-style">
|
||||
<?php
|
||||
<div id="page" class="w-100">
|
||||
<div id="posts" class="animated fadeInLeft ">
|
||||
<div class="p-block puock-text">
|
||||
<div class="timeline no-style">
|
||||
<?php
|
||||
$stat = Typecho_Widget::widget('Widget_Stat');
|
||||
Typecho_Widget::widget('Widget_Contents_Post_Recent', 'pageSize=' . $stat->publishedPostsNum)->to($archives);
|
||||
$year = 0;
|
||||
$mon = 0;
|
||||
$output = '';
|
||||
|
||||
while ($archives->next()) {
|
||||
$year_tmp = date('Y', $archives->created);
|
||||
$mon_tmp = date('m', $archives->created);
|
||||
$day_tmp = date('d', $archives->created);
|
||||
|
||||
// 检查是否需要新的时间线项目
|
||||
if ($year != $year_tmp || $mon != $mon_tmp) {
|
||||
// 如果不是第一个项目,先关闭之前的ul
|
||||
if ($year > 0 && $mon > 0) {
|
||||
$output .= '</ul></div></div>';
|
||||
}
|
||||
|
||||
}
|
||||
$year = $year_tmp;
|
||||
$mon = $mon_tmp;
|
||||
|
||||
// 开始新的时间线项目
|
||||
$output .= '<div class="timeline-item">';
|
||||
$output .= '<div class="timeline-location"></div>';
|
||||
@@ -48,19 +44,15 @@ if (!defined('__TYPECHO_ROOT_DIR__')) exit; ?>
|
||||
$output .= '<h4>' . $year . '-' . $mon . '</h4>';
|
||||
$output .= '<ul class="pd-links pl-0">';
|
||||
}
|
||||
|
||||
// 输出文章项
|
||||
$output .= '<li><a title="' . $archives->title . '" href="' . $archives->permalink . '">';
|
||||
$output .= $archives->title . ' ( ' . $day_tmp . '日 )</a></li>';
|
||||
}
|
||||
|
||||
// 循环结束后关闭最后的标签
|
||||
if ($year > 0 && $mon > 0) {
|
||||
$output .= '</ul></div></div>';
|
||||
}
|
||||
|
||||
echo $output;
|
||||
?>
|
||||
</div> </div> </div> </div> </div>
|
||||
|
||||
<?php $this->need('footer.php'); ?>
|
||||
?>
|
||||
</div></div></div></div></div>
|
||||
<?php $this->need('footer.php'); ?>
|
||||
Reference in New Issue
Block a user