Created
February 3, 2015 11:18
-
-
Save wrightmartin/4d83e19997b4427f34bc to your computer and use it in GitHub Desktop.
Get featured post 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
<div class="case-study__screenshot" | |
<?php if($latest_case_study->has_post_thumbnail()) { | |
$thumb_id = get_post_thumbnail_id(); | |
$thumb_url_array = wp_get_attachment_image_src($thumb_id, 'medium', true); | |
$thumb_url = $thumb_url_array[0]; | |
?> | |
style="background-image: url(<?php $thumb_url ?>);" | |
<?php } ?> | |
> | |
</div> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
try changing line 3 to...