Archived topic
Call the featured image of an other content
3 replies · Started by gregoirenoyelle on June 24, 2020
Hi,
For a custom post type "Creation", I want to call the featured image of a product instead for single and archive page of this content Creation.
For this post type, I have used ACF to make a relation between this two content ("Creation" and "Product"). I have the product ID stored as a meta in my Creation content.
On the forum, I've seen the generate_single_featured_image_output filter.
Could you give me an exemple for calling a featured image of an other content?
Thanks !
Hi there,
I think you will need the post_thumbnail_html() filter
Heres an example of it in use:
Hi David,
Thanks very much for that. This is the one I was looking for :)
Kind regargs,
Grégoire
Glad to hear that :)