我试图让循环只显示ID为53和52的两个标记。没有“if is\\u标记(array(53,52)){”的代码可以运行。我尝试了不同的方法,但无法运行。
提前感谢您的帮助。
<?php
if is_tag( array( 53, 52 ) ){
while ( $projects->have_posts() ) { $projects->the_post(); ?>
<div <?php post_class(); ?>>
<a href="<?php the_permalink(); ?>" class="thumb">
<?php the_post_thumbnail( $image_size ); ?>
<div class="portfolio-hover">
<div class="portfolio-description">
<h4><?php the_title(); ?></h4>
<div><?php the_excerpt(); ?></div>
</div>
</div>
</a>
</div>
<?php
}
}