Advertisement
Guest User

Untitled

a guest
Nov 1st, 2014
149
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.56 KB | None | 0 0
  1. <?php $catquery = new WP_Query( 'post_type=tablighat & taxonomy=tablighatcat & tablighatcat=wr-gift & posts_per_page=1' );
  2. while($catquery->have_posts()) : $catquery->the_post(); ?>
  3.  
  4. <?php global $wp_query;
  5. $postid = $wp_query->post->ID; ?>
  6.  
  7. <?php if (get_post_meta($id, 'ads-url', true)) { ?>
  8. <a href="<?= get_post_meta($id, 'ads-url', true); ?>">
  9. <img src="<?= get_post_meta($id, 'ads-img-url', true); ?>" width="290" height="200" alt="">
  10. </a>
  11. <?php } ?>
  12.  
  13. <?php endwhile; ?>
  14. <?php wp_reset_postdata(); ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement