Post Thumbnail is a theme feature introduced with Version 2.9. Thumbnail is an image that is chosen as the representative image for Posts, Pages or Custom Post Types.

learn more… | top users | synonyms (1)

0
votes
3answers
595 views

get_the_post_thumbnail() returning empty string on custom post type

I've been brought in to help out with development on an existing plugin, and have run into a strange issue. Not sure if I'm overlooking something obvious here. The situation: I'm adding a shortcode ...
0
votes
2answers
591 views

How to add icon over specific thumb

I wanted to do the following, and I know its possible, but I don't know how. I'm looking at in_category, but it doesn't make to much sense. Basically what I want to do, for an example on my homepage, ...
0
votes
0answers
11 views

Get Post thumbnail without width/height attribute

I am wondering if there is an easier/more efficient way to print a post thumbnail without the width/height attributes. I like to control my image sizes with CSS, so I can do things like: width: 30% ...
2
votes
2answers
106 views

Display Category Thumbnail and links in Woo commerce

I would like to display my categories with a thumbnail in woocommerce. I am able to list the child terms as a link but i would like to add additional content. I have added the code below in which I ...
0
votes
0answers
10 views

Show Featured image above post title

I need help with my worpress website, everytime i post a post my featured image ends up on the end of the post like this how to chanage it so that it shows above or below my post title, Thank ...
1
vote
1answer
1k views

How to get Poster (thumbnail) Image of Video

I'm getting all videos using the function below and it's working fine. Now I want to get the videos Poster Image (Thumbnail Image) from that video. How can I get the video Image as thumbnail? I've ...
-1
votes
1answer
14 views

Fetch first image URL from post and set as featured image URL

I would like the theme to fetch the first image URL in the post area and display it as the featured image. This came from an old Affiliates WordPress theme functions.php file. This company has closed ...
1
vote
1answer
1k views

How to set the jpg image compression for specific thumbnail sizes?

This question was asked on Set JPEG compression for specific custom image sizes and answered very nicely by Ahmad M I'd of course comment to that thread but I don't have 50 point reputation... The ...
0
votes
1answer
160 views

Get source from the_post_thumbnail

I'm struggling because I'm using the "Sitewide Tags"-Plugin to grab all posts in a network to the main blog. Now I want to embed the post images to the main blog and the only function you're able to ...
0
votes
1answer
15 views

The location of the html output from the_post_thumbnail();

So I added the_post_thumbnail(); so I can add images through the featured image area in the wordpress. I am trying to add schema to the output since it isn't working by just wrapping ...
0
votes
1answer
34 views

Animated Gif as Featured Image

I am wanting to upload animated gifs to my website and use them as the featured image. I have a couple of questions. Firstly...how do I stop wordpress from automatically resizing the image when I ...
1
vote
1answer
563 views

Cannot get post thumbnails to display

I'm stumped. I've pored over all the articles here and beyond to no avail. I'm trying to simply display the post thumbnail in a template page, but it will not show up. I have thumbnails enabled for ...
0
votes
1answer
13 views

changing size image within the content

I'm trying to get my images inside the post may larger than 800px ; For this I took a function that resizes image here and I'm trying to create a function to my thumb inside the post come with size ...
0
votes
0answers
22 views

Why don't my thumbnails don't work when setting the size in get_the_post_thumbnail()?

I'm using the code below to display a list of posts on my homepage with thumbnail, title, and summary text. The problem I'm having is that rather than using the thumbnail image which is a max size of ...
0
votes
1answer
901 views

Cropping thumbnails to specific dimensions on front end post

Probably not the best title description but here we go. One of my custom post types is for youtube videos which I take the thumb from youtube and upload it as a thumbnail for the post. Now it's easy ...
1
vote
1answer
638 views

Getting Featured Image Caption to Only Show if Populated

Good evening! I'm trying to hide the featured image caption from showing. Currently, it'll show build the div (but not populate it because it's empty). What I'd like to do, ideally, is only show the ...
0
votes
2answers
430 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 ...
1
vote
1answer
500 views

Secondary Featured Image Function (post_thumbnail)

Does anyone know if it is possible to add a secondary Featured image function to the pages and post editor?
0
votes
1answer
22 views

Wanting to change presentation from full post to featured image (post_thumbnail) only

I am working on a blog (http://goo.gl/xazMe0) and this is the code of the index.php: <div id="main-content" class="main-content row"> <div id="primary" class="content-area <?php echo ...
0
votes
1answer
475 views

Random Category with Recent Post Title and Thumbnail

This code below works perfect to pull the title of five random categories, the issue is for each random category I want the latest post title and thumbnail but where and how do I add the post query? ...
1
vote
2answers
464 views

Issue where WP Featured Image will not display

The code I'm using, is outside of WordPress i.e. define('WP_USE_THEMES', false); require('blog/wp-blog-header.php'); global $wpdb; The code that I'm trying to display the post thumbnail (the ...
0
votes
1answer
10 views

Featured images are cropped on index and post page

I am using a theme called Simple Bootstrap and after a recent update, the theme began cropping the height of the featured images on both the index and the post page. When I inspect the specific ...
0
votes
0answers
17 views

Admin panel Thumbnail style cropping for custom post thumbnails?

You know how WordPress allows you to choose the cropped area to display on the by default 150x150 thumbnail size? Is there a way to add your custom thumbnail sizes to the admin panel in the same way? ...
2
votes
2answers
39 views

Query sticky posts with thumbnails

I need to display max 5 latest sticky posts that have a thumbnail. And I need to have accurate counting of the displayed posts. I've tried to exclude sticky posts without a thumbnail with meta_query, ...
0
votes
1answer
491 views

Use Featured Image for backstretch.js

I'm using backstretch.js for full-width header images on my pages. I'm able to grab the Featured Image url like this: <?php $src = wp_get_attachment_image_src(get_post_thumbnail_id($post->ID), ...
0
votes
0answers
20 views

Jetpack Publicize to Twitter: hashtags and images? [on hold]

Is there any way to add one or two tags from the post to the tweet that Jetpack share when Publicize function is enabled? I am quite surprised with the way Publicize works, at least in my case. I ...
0
votes
0answers
19 views

hook wp_get_attachment_image_src

I am using wp pods custom fields for custom post types.. I am holding image links in custom fields. With a hook to "post_thumbnail_html" i fixed thumbnails but when i need wp_get_attachment_image_src ...
0
votes
2answers
30 views

Show LightBox when clicking on featured image [closed]

My WordPress site displays featured images at the top of each post. Here's the PHP code from post.php that generates the featured image. <?php if ( current_theme_supports( 'get-the-image' ) ) ...
0
votes
1answer
30 views

Make the first image the post thumbnail without setting it as the featured image

I want to set a post thumbnail without setting it as featured image. My website is https://www.shockinpoop.com/. If you may, please open any article and you will see that the featured image is ...
0
votes
2answers
425 views

How to make featured image thumbnails on index page load smoother?

I'm using a theme called Hatch Pro, which is a gallery based theme and the index page displays the posts using the featured image. You can see it here. On slower browser environments, the images ...
0
votes
1answer
451 views

How to Make Thumbnail of Post Stay Animated

When I upload my post with an animated .gif, the thumbnail generates into a new image and doesn't stay animated. It will stay animated inside the post which is great. It seems to resize the .gif image ...
0
votes
1answer
483 views

Site not getting correct featured image from my query

On the home page of my site I have a series of tiles that link to various parts of the site. One tile links to the blog and I have written some code to pull the latest post with an image attached to ...
3
votes
2answers
2k views

Featured Image of Video from oembed

For Wordpress, I want to auto generate thumb of the video embedded on a page using oembed? And then save it as a featured image of the post. Any idea how to do this?
0
votes
2answers
484 views

Underscores.me retrieve next / previous post thumbnail in post_nav function

I am using Underscores.me for a project. I'd like to add the featured image (thumbnail) to the previous / next post links. They have a function which I'm trying to edit called THEMENAME_post_nav(). I ...
1
vote
1answer
2k views

How I upload, save and set a featured image from my frontend?

I have a form in my site. This the user register one missing person. I created a custom post type missing person, custom taxonomies and custom fields. All this input's save as well in wp. But I ...
0
votes
1answer
21 views

How risize a thumbnail?

I have a wordpress thumbnail, but i when set the size this (500,200) wordpress resize the imagen and let it square, only 500x500. I set in functions.php add_image_size ('single_post',500,200) In ...
0
votes
1answer
369 views

Extract featured image from link mentioned in blog post

You ever notice Google News has relevant images associated with its headlines? How can I use WordPress to extract a featured image from an external webpage referenced in a blog post (or custom ...
1
vote
4answers
5k views

remove and disable image link in functions.php

Is there a way to disable image or thumbnail link URL, as well as remove existing image/thumbnail links in functions.php? NOT the setting under media as posted in this link, please.
0
votes
1answer
515 views

How to get cropped thumbnail source for custom post type

I need thumbnail image url with size 148*148px. I using custom post type for testimonials. I need just the image source like http://example.com/demoimage.jpg. It is possible to get cropped image ...
0
votes
1answer
34 views

MySQL swap one table for another?

So I have a situation with this WordPress site I'm doing where I have to swap the positions of my featured images. I have two per post thanks to the Multiple Post Thumbnails plugin, but now whatever ...
0
votes
0answers
14 views

“Pagination” for Posts with next/Prev navigation outside loop

I would like to list all posts from a category or all posts on one Page and add a navigation on the right side, so outside the loop which loads my posts. i found this post whick has a similar ...
0
votes
1answer
55 views

Custom image size in the_content loop

I changed the default image dimensions for the "large" thumbnail and re-generated my images using a plugin. The new image size is only shown on new posts created after the image size was created. How ...
0
votes
1answer
57 views

How to get image title/alt attribute?

in my wite theme, there is no alt tag configured in home slider post, i have added alt text with image from media upload. i have added below code to add / retrieve alt tag. but it display blank ...
0
votes
2answers
27 views

wp_get_attachment_image_src always returns full-sized image

https://codex.wordpress.org/Function_Reference/wp_get_attachment_image_src#Parameters leads me to believe wp_get_attachment_image_src( $thumb_id, array(100, 100) )[0] would return a 100x100 thumbnail, ...
0
votes
1answer
37 views

How to add a class to figure tag for featured images?

I'd like to add a class to tag so that the caption for my featured image will show on hover. Currently, this is the code when I use FireBug: <div class="td-post-content"> <div ...
0
votes
2answers
27 views

Post thumbnail on specific template

I know it is possible to have enable post thumbnails on a specific post type, but is there any way of doing this just for specific template?
1
vote
1answer
924 views

Archive show thumbnail

I want to show thumbnails next to my posts in archive page, however it only shows thumbnails if the posts has a featured image. So I want to show thumbnail for the image attached to the post, but I ...
0
votes
2answers
62 views

Wordpress get post thumbnail url

Its simple and answered quite often: I want to get the post thumbnail variable. Even if there is a lot of input, I could not make it work for me. Here is my current code I use somewhere inside my ...
0
votes
0answers
22 views

Get Pagination For List of Wordpress Categories

I'm trying to display a set number of categories on a custom page template. The Categories contains featured image and link to their children. I'm using "Categories Images" plugin to get Category ...
0
votes
0answers
14 views

Export huge sites

I né ed to export data from a comple of sites that contain a lot of posts (tens of thousands). When I try to export all, the procedure fails, I get a partial WXR, so I have to export individual custom ...