0
目前我坚持的问题。我的代码是如何按类别获取最新帖子?
$category_ids = get_all_category_ids();
foreach($category_ids as $kk=> $cat_id) {
$cat_name= query_posts('posts_per_page=1&orderby=date&order=ASC&cat='.$cat_id);
if (have_posts()) :while(have_posts()):the_post
这是我在loop.php文件写的代码我想是通过只显示1后每个类别的类别只取最新帖子按日期
那么实际问题是什么? 'posts_per_page'参数用于确定每页帖子的数量,因此它应该按日期显示唯一的最新帖子... – 2011-02-01 13:12:22