// Add featured image to posts/pages. add_action( 'genesis_entry_content', 'spi_do_featured_image', 1 ); function spi_do_featured_image() { $show_image = get_theme_mod( 'spi_single_image_setting', true ); $img = genesis_get_image( array( 'format' => 'html', 'size' => genesis_get_option( 'image_size' ), 'context' => 'archive', 'attr' => genesis_parse_attr( 'entry-image', array ( 'alt' => get_the_title() ) ), ) ); if ( ! empty( $img ) && is_singular() && ( true === $show_image ) ) { echo $img; } }