Bug in get_post_meta ?
-
Hello, Is this a bug in get_post_meta? This code should display the contents of the field “qanda” for the most recent post in the category “posts.” But nothing shows. Using this wp_query with generating permalinks to the most recent post in “posts” works fine.
This is run inside the loop:
<?php $my_query = new WP_Query('category_name=posts&showposts=1'); ?><?php while ($my_query->have_posts()) : $my_query->the_post(); ?><?php echo get_post_meta($post->ID, "qanda", $single = true); ?><?php endwhile; ?>
Thanks…
Viewing 7 replies - 1 through 7 (of 7 total)
Viewing 7 replies - 1 through 7 (of 7 total)
- The topic ‘Bug in get_post_meta ?’ is closed to new replies.