Featured image in content archives

Homepage Community Forums Ambition Featured image in content archives

Viewing 5 posts - 1 through 5 (of 5 total)
  • Author
    Posts
  • #18789
    Ola
    Customer

      If I activete Featured image in content archives (under Genesis Theme settings) it displays in the content archive as intended but also in the top of every post.

      #18791
      Wes
      Moderator

        Take a look in your functions file and remove or comment out this code –

        //* Add featured image above the entry content
        add_action( 'genesis_entry_header', 'ambition_featured_photo', 5 );
        function ambition_featured_photo() {
        
        	if ( is_attachment() || ! genesis_get_option( 'content_archive_thumbnail' ) )
        		return;
        
        	if ( is_singular() && $image = genesis_get_image( array( 'format' => 'url', 'size' => genesis_get_option( 'image_size' ) ) ) ) {
        		printf( '<div class="featured-image"><img src="%s" alt="%s" class="entry-image"/></div>', $image, the_title_attribute( 'echo=0' ) );
        	}
        
        }

        Let me know if that helps.

        #18798
        Rob
        Customer

          Thanks. This was my issue as well. Wasn’t even a featured image, just an image on the page being used in genesis_entry_header.

          #18809
          Ola
          Customer

            Thanks. That solved the problem.

            #18820
            Wes
            Moderator

              You’re Welcome!

            Viewing 5 posts - 1 through 5 (of 5 total)
            • The topic ‘Featured image in content archives’ is closed to new replies.