the_tags() does not work in WP_Query Loop. A Bug?
-
Hi,
i have installed WP 2.5.1 and trying to view the Tags with the the_tags() function. My Code is below:
<?php $my_query = new WP_Query('showposts=10'); ?> <?php while ($my_query->have_posts()) : $my_query->the_post(); ?> <?php the_title(); ?> <div class="def"><?php the_content(); ?></div> <?php the_tags(); ?> <?php endwhile; ?>
But i does not work for me! I have tried it on multiple installation 2.5 and 2.5.1. But i didnt get it working. When i try the following:
<?php while(have_posts()) : the_post() ?> <?php the_title(); ?> <div class="def"><?php the_content(); ?></div> <?php the_tags(); ?> <?php endwhile; ?>
I mean switch from new WP_Query Object to the default Loop Object it works???? Whats wrong? Is it a Bug?
thanks
yavuz
Viewing 4 replies - 1 through 4 (of 4 total)
Viewing 4 replies - 1 through 4 (of 4 total)
- The topic ‘the_tags() does not work in WP_Query Loop. A Bug?’ is closed to new replies.