Created
June 19, 2014 18:25
-
-
Save freekrai/18c9845778b68766e0d4 to your computer and use it in GitHub Desktop.
call get_thumb_url
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
<?php | |
if(function_exists('has_post_thumbnail') && has_post_thumbnail()) { | |
the_post_thumbnail("loop-image"); | |
}else{ | |
$thumb=get_thumb_url($post->post_content, 'loop-image'); | |
if ($thumb!='') { | |
?> | |
<img src="<?php echo $thumb; ?>" alt="<?php get_the_title(); ?>" /> | |
<?php | |
} | |
} | |
?> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment