R.I.P. Marvin Minsky
erics, January 24th, 2016
1 2 3 4 5 6 7 8 9 10 11 12 13 14 |
add_action( 'genesis_entry_content', 'featured_post_image', 8 ); function featured_post_image() { $categories = get_the_category(); foreach ($categories as $category) { // You can use slug, ID or any other identifier from the WP_Object //if ($category->term_id == 288) { if ($category->slug == 'your-slug-here') { print '<div id="sub-header-image">'; the_post_thumbnail('post-image'); print '</div>'; } } return; } |