boxstyle/content-list.php

50 lines
1.9 KiB
PHP
Raw Permalink Normal View History

2019-01-26 13:01:14 +01:00
<?php $format = get_post_format(); ?>
<article id="post-<?php the_ID(); ?>" <?php post_class('group post-list'); ?>>
2019-01-27 16:17:11 +01:00
<div class="post-inner post-hover <?php if ( !has_post_thumbnail() ) { ?>no-thumbnail<?php } ?>">
2019-01-26 13:01:14 +01:00
2019-01-27 16:17:11 +01:00
<?php if ( has_post_thumbnail() ): ?>
<div class="post-thumbnail">
<a href="<?php the_permalink(); ?>">
2019-01-26 13:01:14 +01:00
<?php the_post_thumbnail('boxstyle-list'); ?>
2019-07-29 15:05:48 +02:00
<?php if ( has_post_format('video') && !is_sticky() ) echo'<span class="thumb-icon"><i class="fas fa-play"></i></span>'; ?>
<?php if ( has_post_format('audio') && !is_sticky() ) echo'<span class="thumb-icon"><i class="fas fa-volume-up"></i></span>'; ?>
<?php if ( is_sticky() ) echo'<span class="thumb-icon"><i class="fas fa-star"></i></span>'; ?>
2019-01-27 16:17:11 +01:00
<?php if ( comments_open() && ( get_theme_mod( 'comment-count', 'on' ) =='on' ) ): ?>
2019-07-29 15:05:48 +02:00
<a class="post-comments" href="<?php comments_link(); ?>"><span><i class="fas fa-comments"></i><?php comments_number( '0', '1', '%' ); ?></span></a>
2019-01-27 16:17:11 +01:00
<?php endif; ?>
</a>
</div><!--/.post-thumbnail-->
<?php else: ?>
<?php endif; ?>
2019-01-26 13:01:14 +01:00
<div class="post-content">
<div class="post-category">
<?php the_category(' / '); ?>
</div><!--/.post-category-->
<h2 class="post-title">
<a href="<?php the_permalink(); ?>" rel="bookmark"><?php the_title(); ?></a>
</h2><!--/.post-title-->
<?php if (get_theme_mod('excerpt-length','26') != '0'): ?>
<div class="entry excerpt">
<?php the_excerpt(); ?>
</div><!--/.entry-->
<?php endif; ?>
<div class="post-date">
2019-07-29 15:05:48 +02:00
<i class="far fa-clock"></i><?php the_time( get_option('date_format') ); ?>
2019-01-26 13:01:14 +01:00
</div><!--/.post-date-->
<?php if ( get_theme_mod( 'format-icon', 'on' ) =='on' ): ?>
<div class="format-circle"><a href="<?php echo get_post_format_link($format); ?>"><i class="fa"></i></a></div>
<?php endif; ?>
</div><!--/.post-content-->
</div><!--/.post-inner-->
</article><!--/.post-->