Wordpress Twenty Eleven PhP - 強制PHP代碼跳過主頁上的第一篇文章?
我已經建立了我的Wordpress,將wordpress Featured Image thumbnails添加到主頁上的所有帖子。
如何讓代碼跳過將wordpress Featured Image thumbnails添加到第一篇文章[the_content()〜在下面的代碼中],並且只將它們添加到wordpress Featured Image thumbnails其他文章[the_excerpt()〜在下面的代碼中]?
代碼我把content.php放在主頁上放wordpress Featured Image thumbnails。 Link Here
<?php if (is_search() | is_home()) : // Edit this to show excerpts in other areas of the theme?>
<div class="entry-summary">
<!-- This adds the post thumbnail/featured image -->
<div class="excerpt-thumb"><a href="<?php the_permalink(); ?>" title="<?php printf(esc_attr__('Permalink to %s', 'twentyeleven'), the_title_attribute('echo=0')); ?>" rel="bookmark">
<?php the_post_thumbnail('excerpt-thumbnail', 'class=alignleft'); ?></a></div>
<?php if($wp_query->current_post == 0 && !is_paged()) { the_content(); } else { the_excerpt(); } ?>
</div><!-- .entry-summary -->
<?php else : ?>
<div class="entry-content">
<?php the_content(__('Continue reading <span class="meta-nav">→</span>', 'twentyeleven')); ?>
<?php wp_link_pages(array('before' => '<div class="page-link"><span>' . __('Pages:', 'twentyeleven') . '</span>', 'after' => '</div>')); ?>
</div><!-- .entry-content -->
<?php endif; ?>
請不要忘記注意事項 – user2284570