| 1 |
<?php |
| 2 |
|
| 3 |
if ( ! defined( 'ABSPATH' ) ) { |
| 4 |
exit; // Exit if accessed directly |
| 5 |
} |
| 6 |
global $post; |
| 7 |
$user = uwp_get_displayed_user(); |
| 8 |
?> |
| 9 |
<li class="uwp-profile-item-li uwp-profile-item-clearfix"> |
| 10 |
<div class="uwp_generic_thumb_wrap"> |
| 11 |
<a class="uwp-profile-item-img" href="<?php echo esc_url_raw( get_the_permalink() ); ?>"> |
| 12 |
<?php |
| 13 |
if ( has_post_thumbnail() ) { |
| 14 |
$thumb_url = get_the_post_thumbnail_url( get_the_ID(), array( 80, 80 ) ); |
| 15 |
} else { |
| 16 |
$thumb_url = uwp_get_default_thumb_uri(); |
| 17 |
} |
| 18 |
?> |
| 19 |
<img class="uwp-profile-item-alignleft uwp-profile-item-thumb" src="<?php echo esc_url_raw( $thumb_url ); ?>"> |
| 20 |
</a> |
| 21 |
</div> |
| 22 |
|
| 23 |
<h3 class="uwp-profile-item-title"> |
| 24 |
<a href="<?php echo esc_url_raw( get_the_permalink() ); ?>"><?php echo esc_html( get_the_title() ); ?></a> |
| 25 |
</h3> |
| 26 |
<time class="uwp-profile-item-time published" datetime="<?php echo esc_attr( get_the_time( 'c' ) ); ?>"> |
| 27 |
<?php echo get_the_date(); ?> |
| 28 |
</time> |
| 29 |
<div class="uwp-profile-item-summary"> |
| 30 |
<?php |
| 31 |
do_action( 'uwp_before_profile_summary', get_the_ID(), $post->post_author, $post->post_type ); |
| 32 |
$excerpt = strip_shortcodes( wp_trim_words( get_the_excerpt(), 15, '...' ) ); |
| 33 |
echo esc_attr( $excerpt ); |
| 34 |
do_action( 'uwp_after_profile_summary', get_the_ID(), $post->post_author, $post->post_type ); |
| 35 |
?> |
| 36 |
</div> |
| 37 |
</li> |