Advertisement
Guest User

Untitled

a guest
Feb 10th, 2013
47
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 0.60 KB | None | 0 0
  1. <?php
  2.             $args = array( 'post_type' => 'product', 'posts_per_page' => 1, 'product_tag' => 'awesome', 'orderby' => '' );
  3.             $loop = new WP_Query( $args );
  4.             while ( $loop->have_posts() ) : $loop->the_post(); global $product; ?>
  5.               <div id="feat-img-contain">
  6.                        <a href="<?php echo get_post_meta($post->ID, 'vendor-url', true); ?>"> <?php if ( has_post_thumbnail() ) {
  7.                            the_post_thumbnail();}?></a>
  8.               </div><!--end feat-img-contain-->
  9.            <?php endwhile; ?>
  10.  
  11.             <?php wp_reset_query(); ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement