0
votes
2answers
187 views

Display Random Thumbnail from Category

I have a feeling that I'm on the right track, I just don't have enough solid PHP knowledge to get much further than where I'm currently at. I'm currently using the following code to return a list of ...
0
votes
1answer
600 views

Display post thumbnail in foreach loop

I am trying to display a thumbnail in a foreach loop. The thumbnail is a new image size I have added called "plant-thumb". I have all the desired elements displaying properly except for the thumbnail. ...
0
votes
1answer
404 views

Why use foreach to get attachment_id if numberposts is equal to 1?

I needed to pass an image to a Pinterest plugin in posts without a Featured Image so I wrote a little function to get the id of the first picture in a post. This code is in the loop-single.php where ...
0
votes
2answers
224 views

How to check all items in a loop have post thumbnail?

Currently I have the following loop: <?php $shows_sales = get_posts(array( 'post_type' => 'show_sale', 'post_status' => 'publish', 'posts_per_page' => 3, )); $done_image = ...