Automatically Display Featured Image At The Top Of Pages WordPress

function my_page_featured_image() {
	if ( is_page() && has_post_thumbnail() ) {
		echo '<div class="my-page-featured-image clr">'. get_the_post_thumbnail() .'</div>';
	}
}
add_action( 'wpex_hook_main_top', 'my_page_featured_image', 10 );
See also  CSS Only Cross-fading Image Slideshow

Leave a Reply

Your email address will not be published. Required fields are marked *