## How to find attachment by it’s name?

Question
Is it possible to get attachment id by its name? And at once may be it's possible to get parent post, to which this attachment is assigned?
0
3 months 0 Answers 50 views

## Resizing images only for WooCommerce categories

Question
I'm trying to resize images just for category pages for a WooCommerce site I'm building. Essentially, I want image square throughout the site, but 3:4 for WooCommerce categories. I thought this code would work in my functions.php, but I'm obviously doing something ...
0
3 months 0 Answers 45 views

Question
I want to use a default image as a featured image for all those Posts and Pages, where is not any selected featured image from media. I have tried this code in function.php but not working, function filter_post_thumbnail( $html ) { if ... 0 3 months 0 Answers 44 views ## Post featured image column on admin post list page Question I have a client site which accepts images from users as posts. For moderation, we are opening each draft post which obviously takes a lot of time if a hefty amount of images are moderated. So, Is there a way ... 0 4 months 0 Answers 47 views ## Is it possible to set Featured Image using HTML? Question The Amazon affiliate program does not let you download images from their site and upload it via their server. One authorized way of using images from Amazon is to use their API or Sitestripe. For new affiliates that haven't made ... 0 4 months 0 Answers 47 views ## retrieve and display thumbnail from post ID of best selling product within product_tag taxonomy Question I have used the below code to retrieve and display the thumbnail of best selling product from each product tag. The product tags are listed as required, however the thumbnail is not displayed on hover.$max_tag_count = 14; // this is ...
0
4 months 0 Answers 42 views

## retrieve thumbnail from post ID of best selling product within product_tag taxonomy

Question
I have used the below code to retrieve the thumbnail of best selling product within a product category and thought I could do the same for product tags by simply switching out the taxonomy to product_tag, however it has not ...
0
4 months 0 Answers 43 views

## How to display image sizes in API embedded?

Question
I have just used regenerate images tool to regenerate image sizes and it was successful though I need those image sizes to show up in wp rest api when calling post in _embedded field. As you can see it's an ...
0
4 months 0 Answers 45 views

## Category images are not displaying in WordPress

Question
I have categories list with there respective images. I am able to get the category name and description but I am not getting the category image. I tried the below code. <ul> <?php \$categories = get_categories( array( ...
0
4 months 0 Answers 41 views

## Have get_the_post_thumbnail output different image if custom meta exists

Question
I have a meta box on each post where a user is able to select another image from the media library. I want this image to override the output whenever get_the_post_thumbnail is used across the whole theme. I've looked through the wp-includes/post-thumbnail-template.php ...
0
4 months 0 Answers 41 views