SHARE
TWEET

Untitled

a guest Feb 10th, 2013 25 Never
  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(); ?>
RAW Paste Data
Top