Just a heads up, I’m going to be replacing the Featured Image code in the functions file. Here’s what the new updated code will look like –
// Add featured image above the entry content
add_action( 'genesis_before_entry', 'aspire_featured_photo' );
function aspire_featured_photo() {
if ( ! ( is_singular() && has_post_thumbnail() ) ) {
return;
}
$image = genesis_get_image( 'format=url&size=single-posts' );
$thumb_id = get_post_thumbnail_id( get_the_ID() );
$alt = get_post_meta( $thumb_id, '_wp_attachment_image_alt', true );
if ( '' == $alt ) {
$alt = the_title_attribute( 'echo=0' );
}
printf( '<div class="featured-image"><img src="%s" alt="%s" class="entry-image"/></div>', esc_url( $image ), $alt );
}
That fixes a couple issues like the featured image not going away on certain pages and a few other things as well.