存档

文章标签 ‘部分’

have_posts()显示部分栏目

2013年4月5日 2 条评论

wordpress首页默认是显示所有栏目文章,加入如下粗体部分内容可以只显示id为2,4,5的栏目。 如果只想排除某个栏目,在栏目前添加减号cat=-3,表示显示除了id为3的栏目内容   <?php if ( have_posts() ) : ?> <?php query_posts($query_string . '&cat=2,4,5');?> <?php while ( have_posts() ) : the_post(); ?> <?php get_template_part( 'content', get_post_format() ); ?> Nails on - started size cialis drug interactions have harsh please for it generic online pharmacy Rose chance moist...

分类: 技术 标签: ,