【发布时间】:2013-09-06 19:21:14
【问题描述】:
我的页面模板有这个代码。
这就是我现在拥有的:http://www.ohright.com/emoticons/
如何更改它,以便它可以以每页 20 张图片的形式显示我所有的帖子图片,并在下方分页?
<?php
/*
Template Name: emoticons-page
*/
get_header(); ?>
<div id="content">
<div id="main">
<?php query_posts('cat=44'.get_the_title().'&post_status=publish,future');?>
<?php if ( have_posts() ) : while ( have_posts() ) : the_post(); ?>
<h1><a href="<?php the_permalink(); ?>"><?php the_title(); ?></a></h1>
<p><?php the_content(); ?>
<?php endwhile; else: endif; ?>
</div>
</div>
<?php get_footer(); ?>
【问题讨论】:
-
你可以使用
'posts_per_page' => 20
标签: php jquery wordpress pagination