summaryrefslogtreecommitdiff
path: root/links.php
diff options
context:
space:
mode:
Diffstat (limited to 'links.php')
-rw-r--r--links.php17
1 files changed, 8 insertions, 9 deletions
diff --git a/links.php b/links.php
index b0975cd..0628f79 100644
--- a/links.php
+++ b/links.php
@@ -17,20 +17,22 @@ $this->need('includes/header.php'); ?>
<br />
<article class="item">
+ <?php if($this->fields->banner && $this->fields->banner!='') :?>
<div class="post-banner">
- <?php if($this->fields->banner && $this->fields->banner!='') :?>
<div class="media-banner" style="background-position:center center;background:url(<?php $this->fields->banner(); ?>);background-repeat:no-repeat;background-size:cover;"></div>
- <?php else: ?>
- <div class="media-banner" style="background-position:center center;background:url(<?php $this->fields->default_banner(); ?>);background-repeat:no-repeat;background-size:cover;"></div>
- <?php endif; ?>
+ </div>
+ <?php endif; ?>
+
<div class="post-header">
<h2><?php $this->title() ?></h4>
<span>
<i class="glyphicon glyphicon-time"></i> <?php $this->date('Y-m-d'); ?>&nbsp;&nbsp;/&nbsp;&nbsp;
+ <i class="glyphicon glyphicon-bookmark"></i> <?php $this->category(',', true, '木有分类'); ?>&nbsp;&nbsp;/&nbsp;&nbsp;
<i class="glyphicon glyphicon-comment"></i> <?php $this->commentsNum('%d'); ?>
</span>
</div>
- </div>
+
+ <hr />
<div class="links-box">
<h2>友链墙</h2>
@@ -42,10 +44,7 @@ $this->need('includes/header.php'); ?>
<hr />
<div class="post-content">
- <?php
- $content = preg_replace('/<img(.*?)src="(.*?)"(.*?)>/s','<a data-fancybox="gallery" href="${2}"><img${1}src="${2}"${3}></a>',$this->content);
- echo $content
- ?>
+ <?php $this->need('includes/post-content.php'); ?>
</div>
</article>