要调用最新推荐的7条数据,以下代码怎么改 呢?
{{{<?php foreach($this->posts_list as $key => $val) { ?>
<?php if ($val['is_recommend']) { ?>
<li class="fh">
<h4>
<?php if ($val['question_id']) { ?> <a href="question/<?php echo $val['question_id']; ?>"><?php echo $val['question_content']; ?></a>
<?php } else { ?>
<a href="article/<?php echo $val['id']; ?>"><?php echo $val['title']; ?></a> <?php } ?>
</h4>
</li>
<?php } ?>
<?php } ?>}}}
阅读全文
收起全文