i have created a custom post named Products.
register_post_type( 'products',
array(
'labels' => array(
'name' => __( 'Products' ),
'singular_name' => __( 'Product' )
),
'public' => true,
'has_archive' => true,
'supports' => array( 'title', 'editor', 'thumbnail' )
);
I have also created a php file named archive-products.php and made it into a template.
In Wordpress I have created a page named Products and selected the products template.
On that static page (that uses the archive template) I have uploaded a image into the Featured Image panel.
In my header I have the code:
echo get_the_post_thumbnail();
But this echos the Featured image of the last custom post in the list (all the products posts have a featured image as well), not the Featured image of the static/archive page, which is what i want. Is this possible to achieve?
Thanks!