blog, Uncategorized, Website Design

Remove Minimum Theme Post Thumbnail Images

Labadie GM Blog Image

I was working on the look of the blog for Labadie Buick GMC Cadillac.  I wanted a very basic look but wanted to make sure it worked well with cell phones (responsive).  I decided on the Minimum theme from Studio Press.  Because I imported the content from a different URL the posts all had a featured image.  When I installed the Minimum theme the default is for each post page to display the featured image.  But I didn’t want that.  I did a search in the StudioPress Forum and didn’t find anything.

So I went into the functions.php code and deleted lines 66-77 or:

/** Add the featured image section */
add_action( ‘genesis_after_header’, ‘minimum_featured_image’ );
function minimum_featured_image() {
if ( is_home() ) {
echo ‘<div id=”featured-image”><img src=”‘. get_stylesheet_directory_uri() . ‘/images/sample.jpg” /></div>’;
}
elseif ( is_singular( array( ‘post’, ‘page’ ) ) && has_post_thumbnail() ){
echo ‘<div id=”featured-image”>’;
echo get_the_post_thumbnail($thumbnail->ID, ‘header’);
echo ‘</div>’;
}
}

This removed the thumbnail images from the post pages but also removed the image from the home page.  I wanted the image on the homepage.  I went back into the functions.php and simply removed lines 71-76 so that the code now looked like this:

/** Add the page title section */
add_action( ‘genesis_after_header’, ‘minimum_page_title’ );
function minimum_page_title() {
require_once( get_stylesheet_directory() . ‘/page-title.php’ );
}

This worked.  Now I have the featured image on the homepage but no featured images on the blog post pages.  You can view the Labadie Buick GMC Cadillac blog at:  http://blog.labadiegm.com