Community Forums › Forums › Archived Forums › Design Tips and Tricks › Genesis 2.0 Portfolio Shows Unwanted Thumbnails
Tagged: genesis 2.0 portfolio
- This topic has 3 replies, 2 voices, and was last updated 12 years, 10 months ago by
Marcy.
-
AuthorPosts
-
August 7, 2013 at 2:31 pm #54685
pxforti
ParticipantI modified genesis portfolio code from minimum template to work with Genesis 2.0 beta with Genesis 2.0 Sample theme with HTML 5 turned on and all was good. My portfolio archive page showed the individual portfolio titles and featured images.
Now that I have upgraded to Genesis 2.0 release, my portfolio archive page now shows a thumbnail image below each featured image.
Below is my portfolio archive page code. Any idea why I'm getting thumbnails below the featured image?
Thanks
<?php /** * The custom portfolio post type archive template */ /** Force full width content layout */ add_filter( 'genesis_pre_get_option_site_layout', '__genesis_return_full_width_content' ); /** Remove the post info function */ remove_action( 'genesis_entry_header', 'genesis_post_info' ); /** Remove the post content */ remove_action( 'genesis_entry_content', 'genesis_do_post_content' ); /** Remove the post image */ remove_action( 'genesis_entry_content', 'genesis_do_post_image' ); /* Add portfolio title */ add_action('genesis_before_content', 'wnd_portfolio_title'); function wnd_portfolio_title() { ?> <header class="entry-header porthead"><h1 class="entry-title" itemprop="headline">WriteNowDesign Portfolio</h1></header> <?php } /** Add the featured image after post title */ add_action( 'genesis_entry_header', 'minimum_portfolio_grid' ); function minimum_portfolio_grid() { if ( has_post_thumbnail() ){ echo '<div class="portfolio-featured-image">'; echo '<a href="' . get_permalink() .'" title="' . the_title_attribute( 'echo=0' ) . '">'; echo get_the_post_thumbnail($thumbnail->ID, 'portfolio' ); echo '</a>'; echo '</div>'; } } /** Remove the post meta function */ remove_action( 'genesis_entry_footer', 'genesis_post_meta' ); genesis();
http://writenowdesign.com/portfolio/writeNowDesign
WordPress and Ecommerce Website DesignAugust 7, 2013 at 2:34 pm #54689pxforti
ParticipantNote: I just commented out remove_action( 'genesis_entry_content', 'genesis_do_post_image' ); and there was no change.
It is possible that genesis_do_post_image has a bug and it not working because of that?
writeNowDesign
WordPress and Ecommerce Website DesignAugust 7, 2013 at 6:31 pm #54766pxforti
ParticipantFinally figured this one out.
remove_action( 'genesis_entry_content', 'genesis_do_post_image', 8 );
I added a priority of 8 to the remove action, same as in the genesis post.php add_action( 'genesis_entry_content', 'genesis_do_post_image', 8 );
writeNowDesign
WordPress and Ecommerce Website DesignAugust 7, 2013 at 7:05 pm #54774Marcy
ParticipantYes, I was just going to ask if you had tried that. Saw this post a bit ago, and but just saw the fix.
Marcy | Amethyst Website Design | Twitter
-
AuthorPosts
- The forum ‘Design Tips and Tricks’ is closed to new topics and replies.