-
Notifications
You must be signed in to change notification settings - Fork 78
/
index.php
59 lines (56 loc) · 2.62 KB
/
index.php
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
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
<?php
/**
* 大前端主题修改版 for Typecho
*
* @package DUX主题
* @author 大前端 (由 hiCasper 修改)
* @version 1.0
* @link https://github.com/hiCasper/Typecho-theme-DUX
*/
if (!defined('__TYPECHO_ROOT_DIR__')) exit;
$this->need('header.php');?>
<section class="container">
<div class="content-wrap">
<div class="content">
<?php if($this->_currentPage==1): ?>
<!--幻灯片开始-->
<?php if ($this->options->Slider == 'SliderTrue'): ?>
<?php slout(); ?>
<?php endif; ?>
<!--幻灯片结束-->
<?php endif; ?>
<!--置顶文章-->
<?php hotpost(); ?>
<div class="title">
<h3>最新发布</h3>
<?php if($this->options->smallbanner && !empty($this->options->smallbanner) ): ?>
<div class="more"><?php $this->options->smallbanner(); ?></div><?php endif; ?>
</div>
<?php if($this->have()):?>
<?php while($this->next()): ?>
<article class="excerpt">
<?php if ($this->options->indexpic == 'able'): ?>
<a class="focus" href="<?php $this->permalink() ?>"><img src="<?php $this->options->themeUrl('img/thumbnail.png'); ?>" data-src="<?php echo showThumb($this,null,true); ?>" class="thumb"></a>
<?php endif; ?>
<header>
<a class="cat"><?php $this->category(',',false); ?><i></i></a>
<h2><a href="<?php $this->permalink() ?>" title="<?php $this->title() ?>-<?php $this->options->title();?>"><?php $this->title() ?></a></h2>
</header>
<p class="meta">
<time><i class="fa fa-clock-o"></i><?php $this->date('Y-m-d'); ?></time>
<span class="author"><i class="fa fa-user"></i><?php $this->author(); ?></span>
<span class="pv"><i class="fa fa-eye"></i>阅读(<?php get_post_view($this) ?>)</span>
<a class="pc" href="<?php $this->permalink() ?>#comments"><i class="fa fa-comments-o"></i>评论(<?php $this->commentsNum('0', '1', '%d'); ?>)</a>
</p>
<p class="note"><?php $this->excerpt(111, '...'); ?></p>
</article>
<?php endwhile; ?>
<?php endif; ?>
<div class="pagination">
<?php $this->pageNav('上一页', '下一页', 3, '...', array('wrapTag' => 'ul', 'wrapClass' => 'page-navigator', 'itemTag' => 'li', 'textTag' => 'span', 'currentClass' => 'active', 'prevClass' => 'prev-page', 'nextClass' => 'next-page')); ?>
</div>
</div>
</div>
<?php $this->need('sidebar.php'); ?>
</section>
<?php $this->need('footer.php'); ?>