</div> <div class="main-box home-box-list">'; foreach ($articledb as $article) { echo ' <div class="post-list"> <div class="item-avatar"><a href="/user/', $article['uid'], '"> <img src="/avatar/normal/', $article['uavatar'], '.png" alt="', $article['author'], '" /> </a></div> <div class="item-content count', $article['comments'], '"> <h1><a rel="bookmark" href="/topics/', $article['id'], '">', $article['title'], '</a></h1> <span class="item-date"><i class="fa fa-archive"></i> <a href="/nodes/', $article['cid'], '">', $article['cname'], '</a>'; if ($article['comments']) { echo ' <i class="fa fa-user"></i> <a href="/user/', $article['ruid'], '">', $article['rauthor'], '</a> <i class="fa fa-clock-o"></i> <time datetime="', showtime2($article['edittime']), '" pubdate="pubdate" data-updated="true">', showtime($article['edittime']), '</time>回复'; } else { echo ' <i class="fa fa-user"></i> <a href="/user/', $article['uid'], '">', $article['author'], '</a> <i class="fa fa-clock-o"></i> <time datetime="', showtime2($article['addtime']), '" pubdate="pubdate" data-updated="true">', showtime($article['addtime']), '</time>发表'; } echo ' </span> </div>'; if ($article['comments']) { $gotopage = ceil($article['comments'] / $options['commentlist_num']); if ($gotopage == 1) { $c_page = ''; } else { $c_page = '/' . $gotopage; } echo '<div class="item-count"><a href="/topics/', $article['id'], $c_page, '#reply', $article['comments'], '">', $article['comments'], '</a></div>'; } echo ' <div class="c"></div> </div>'; }
echo ' <div class="post-list"> <div class="item-avatar"><a href="/user/', $article['uid'], '">'; if (!$is_spider) { echo '<img src="/avatar/large/', $article['uavatar'], '.png" alt="', $article['author'], '" />'; } else { echo '<img src="/static/grey.gif" data-original="/avatar/large/', $article['uavatar'], '.png" alt="', $article['author'], '" />'; } echo ' </a></div> <div class="item-content"> <h1><a rel="bookmark" href="/topics/', $article['id'], '">', $article['title'], '</a></h1> <span class="item-date"><i class="fa fa-archive"></i> <a href="/nodes/', $article['cid'], '">', $article['cname'], '</a> <i class="fa fa-user"></i> <a href="/user/', $article['uid'], '">', $article['author'], '</a>'; if ($article['comments']) { echo ' <i class="fa fa-clock-o"></i> <time datetime="', showtime2($article['edittime']), '" pubdate="pubdate" data-updated="true">', showtime($article['edittime']), '</time> <i class="fa fa-user-secret"></i> 最后回复来自 <a href="/user/', $article['ruid'], '">', $article['rauthor'], '</a>'; } else { echo ' <i class="fa fa-clock-o"></i> <time datetime="', showtime2($article['addtime']), '" pubdate="pubdate" data-updated="true">', showtime($article['addtime']), '</time>'; } echo ' </span> </div>'; if ($article['comments']) { $gotopage = ceil($article['comments'] / $options['commentlist_num']); if ($gotopage == 1) { $c_page = ''; } else { $c_page = '/' . $gotopage; } echo '<div class="item-count"><a href="/topics/', $article['id'], $c_page, '#reply', $article['comments'], '">', $article['comments'], '</a></div>'; } echo ' <div class="c"></div> </div>'; }
if ($t_obj['relative_topics']) { echo '<div class="has_adv"><h3>相关帖子:</h3>'; echo '<ul class="rel_list">'; foreach ($t_obj['relative_topics'] as $rel_t_obj) { echo '<li><a href="/topics/', $rel_t_obj['id'], '" title="', $rel_t_obj['title'], '">', $rel_t_obj['title'], '</a></li>'; } echo '<div class="c"></div></ul><div class="c"></div></div>'; } echo '</div> </div> <!-- post main content end -->'; if ($t_obj['comments']) { echo ' <div class="nav-title"> ', $t_obj['comments'], ' 回复 | 直到 ', showtime2($t_obj['edittime']), ' </div> <div class="main-box home-box-list">'; $count_n = ($page - 1) * $options['commentlist_num']; foreach ($commentdb as $comment) { $count_n += 1; echo ' <div class="commont-item"> <div class="commont-avatar"><a href="/user/', $comment['uid'], '"><img src="/avatar/mini/', $comment['avatar'], '.png" alt="', $comment['author'], '" /></a></div> <div class="commont-data"> <div class="commont-content"> <p>', $comment['content'], '</p> </div> <div class="commont-data-date"> <div class="float-left"><i class="fa fa-user"></i> <a href="/user/', $comment['uid'], '">', $comment['author'], '</a> <i class="fa fa-calendar"></i> ', $comment['addtime'];