Query specific post ID's Problem
-
Hi all, I followed the directions on WordPress’s site regarding querying, and I came up with this. For some reason it’s not displaying at all. What am I missing?
My goal is to loop a formatted list of only specific post ID’s.
Any help would be greatly appreciated.
<ul> <?php $home_loop_query = new WP_Query(array('tag__and'=>array( 74,175,174,173,69,62))); while($home_loop_query->have_posts()) : $home_loop_query->the_post(); $thumbnail_src = wp_get_attachment_image_src( get_post_thumbnail_id($post->ID), array(), false, '' ); ?> <li style="background: url('<?php echo $thumbnail_src[0]; ?>') no-repeat center center; background-size: cover;"> <li style="background: url('<?php echo $thumbnail_src[0]; ?>') no-repeat center center / cover;"> <div class="col2-post-content"> <div class="col2-category"> <?php $category = get_the_category(); echo $category[0]->cat_name; ?> </div> <h3><a href="<?php the_permalink() ?>" rel="bookmark"><?php the_title(); ?></a></h3> </div> </li> <?php endwhile; ?> </ul>
Viewing 1 replies (of 1 total)
Viewing 1 replies (of 1 total)
- The topic ‘Query specific post ID's Problem’ is closed to new replies.