Getting featured image of blog page rather than post image


I have a page called “Blog” which uses “Default Template” (index.php). It has a featured image. I want to display this image, but when I use get_post_thumbnail_id(), inside or outside the loop, I get the thumbnail of the first post on my blog, not the one of my “Blog” page.

Just in case, in Settings > Reading, Posts Page is set as “Blog”

drake035 4 years 2020-05-25T13:10:26-05:00 0 Answers 95 views 0

Leave an answer