Created
May 16, 2013 17:14
-
-
Save lucasstark/5593386 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
global $post; | |
if (basename( get_page_template() ) != 'some-template.php') { | |
$featured_image_post = get_featured_recursive($post); | |
if ($featured_image_post != null) { | |
$featured_image_src = wp_get_attachment_image_src(get_post_thumbnail_id($featured_image_post), 'single-post-thumbnail'); ?> | |
<img src="<?php echo $featured_image_src[0]; ?>" alt="<?php the_title(); ?>" /> | |
<?php } | |
else { | |
if (has_post_thumbnail()){ | |
//output the thumbnail normally | |
} | |
} | |
?> | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment