-1
您好,我想創建歸檔/分類/標籤創建多個循環頁
多回路頁我很困惑,plz幫助
<?php
$count = 1;
if (have_posts()) : while (have_posts()) : the_post();
if($count == 1) : ?>
< - 第一環 - >我需要只有1在此迴路後(所以我添加上面的代碼)
<?php else : ?>
<?php the_post_thumbnail(); ?>
<a href="<?php the_permalink() ?>" rel="bookmark"><?php the_title(); ?></a>
<?php echo limit_words(get_the_excerpt(), '44'); ?>
< - 第二環 - >(1周後在該循環中)
<a href="<?php the_permalink() ?>" rel="bookmark"><?php the_title(); ?></a>
<?php echo limit_words(get_the_excerpt(), '35'); ?>
< - 三環路 - >(4職位在這個循環中)
<ul><li><a href="<?php the_permalink() ?>" rel="bookmark"><?php the_title(); ?></a>
</li></ul>
< - 四迴路 - >(所有帖子的其餘部分將在這個循環中)
<?php the_post_thumbnail('thumbnail', array('class' => 'cover')); ?>
<div class=""></div><a href="<?php the_permalink() ?>"><?php the_title(); ?></a>
<?php echo limit_words(get_the_excerpt(), '44'); ?></div>
<?php endif; ?>
<?php $count++; ?>
<?php endwhile; ?>
</div><!-- /.post -->
<?php else : ?>
<h2 class="archiveTitle"><?php _e('Sorry, nothing matched your criteria','linepress');?></h2>
<?php endif; ?>
我試過但失敗 – atali 2011-10-17 16:06:28