If you’re not opposed to using a plugin to achieve this, I would recommend the Multiple Post Thumbnails plugin. It’s very simple to use and provides the same functionality as “the_post_thumbnail()” function.
Related Posts:
- How to disable WordPress from creating thumbnails?
- set_post_thumbnail_size vs add_image_size
- the_post_thumbnail responsive srcset not populating with custom image size
- Set custom name for generated thumbnails
- New image size version only for the Featured Image file
- wp_get_attachment_image_src always returns full-sized image
- Add Title Attribute to WordPress Image the_post_thumbnail
- Image uploader with “Set Featured Image” link on front end
- Can WordPress crop only the post thumbnails?
- Query the post which have a thumbnail
- Autogenerated Thumbnail compression depending on size
- Media thumbnail for custom post inside post content
- Thumbnail and Featured Image With Fixed Sizes?
- List category posts – Thumbnails are not displaying
- Why am I getting errors in product.thumbnails.php? [closed]
- Is there a way to change a post’s thumbnail image(s)?
- how i can increase Featured thumbnails size?
- How check that there is post thumbnail feature image or not on wordpress?
- Force WordPress to strip/remove EXIF/IPTC metadata when resizing thumbnails
- If I Regenerate Thumbnails, would WordPress delete the existing Thumbnails and replace them with ‘new copies’?
- Is it possible to nest get_previous_post()?
- How to get cropped thumbnail source for custom post type
- Get ID of featured image using “get_post_thumbnail_id(the_ID())” – without printing to screen?
- How to offset thumbnails to the center?
- Sidebar Thumbs Squished?
- Aligning the thumbnail image
- Post thumbnail not working after regenerate
- How do get post thumbnail into plugin?
- “Medium” size image displayed instead of “thumbnail” in only one post, other posts are fine
- How to create resized versions of images added with wp_insert_attachment
- get_post_thumbnail_id() Doesn’t return value [closed]
- How To Add and Display Category Image
- get_the_post_thumbnail(‘thumbnail-name’) always returns empty string
- Can’t get post thumbnail to display in foreach loop
- Show posts image attachments
- Thumbnail is showing outside its div instead of inside it
- get_post_thumbnail does not display thumbnail
- Category page with thumb is ok but can’t do the same with tags
- how can I call a posts featured image in any template?
- how to resize thumbnail image
- Different thumbnails for index and article page
- Thumbnails not being generated for PDF files
- Thumbnail size problem Desktop vs Mobile site
- How do you code a featured image into an XML as a jpg link, instead of using a data-id number?
- How to change the format of thumbnails into wordpress theme?
- display div tag only if post has thumbnail
- Thumbnails are hard cropped not matter what
- Thumbnails regenerate wp_generate_attachment_metadata
- Featured image size always cropped bottom
- set_post_thumbnail() shows Unattached on backend under Media
- Allow ‘Set featured images’ to select multiple images
- Why wordpress doesn’t generate thumbnails?
- Force Regenerate Thumbnails Not Working
- Trouble Retrieving Thumbnail URL on Front-Page
- I would like my posts to pull my custom cropped thumbnail instead of creating its own thumbnail from Featured Image
- WordPress save thumbnail but don’t show it [closed]
- Automatic adding thumbnail to post
- Different thumbnail size than actual picture in post
- Where is the template from the_post_thumbnail()?
- Images thumbnail not cropping square
- Delete original image – keep thumbnail?
- Getting Thumbnail Path rather than Image Tag
- adding an id to the_post_thumbnail
- How can I display my featured image correctly inside my single posts?
- How to get_posts having post thumbnail?
- Get Ancestor featured image
- How to make thumbnail image fit into a div where image dimentions are completely different?
- Confused with the loop and repeating things
- Looking for Add Title Tag on Feature Images on WP
- how to link post-thumbnail to original img in a lightbox?
- Notice: Trying to get property of non-object when trying to get thumbnail URL
- Add padding while generating thumbnail
- How do I remove featured images and captions from a wordpress RSS feed?
- How to fit image to Thumbnail canvas size?
- Custom image size in the_content loop
- Recent posts on homepage: different thumbnail based on logged in status and post category
- Images uploaded on frontend display correctly but not in media editor.
- Facebook Does Not Grab Correct og:Image
- Is it possible to add the_post_thumbnail to style.css?
- Getting featured image of particular size.
- Smaller thumbnail in the_content
- Get post featured image id with $wpdb
- Attachment Image using wrong src?
- Unable to set Custom “Link URL” for Featured Image, and More?
- First Image not loading on Mobile Version of Website
- Is it possible to set Featured Image using HTML?
- Does WordPress have a way of changing the ‘Natural’ size of uploaded images?
- wp_get_attachment_metadata()[‘image_meta’] fetch WP metadata or EXIF?
- White Blank screen and issue to get thumbnail in
- Post thumbnail on specific template
- Using lower resolution/size images for thumbnails on posts index
- Featured Image metabox (postimagediv) doesn’t appears when it should
- Thumbnails not showing in blog
- Featured Image inserted through custom query, does not show up
- Change role’s settings influence post-thumbnail
- Wrap Featured Image in a Link
- Thumbnail images
- Featured Image Isn’t showing with cropped, How to show it?
- php code for image fetching
- the_ID & wp_get_attachment_image_src(the_ID(), “medium”) blank