initial commit
This commit is contained in:
57
loop.php
Normal file
57
loop.php
Normal file
@@ -0,0 +1,57 @@
|
||||
<?php if (have_posts()): while (have_posts()): the_post();?>
|
||||
|
||||
|
||||
<article id="post-<?php the_ID();?>" <?php post_class();?>>
|
||||
|
||||
<!-- post thumbnail -->
|
||||
<?php if (has_post_thumbnail()): // Check if thumbnail exists ?>
|
||||
<a class="thumbnailwrapper" href="<?php the_permalink();?>" title="<?php the_title();?>">
|
||||
<?php the_post_thumbnail('home-thumbnail');?>
|
||||
</a>
|
||||
<?php endif;?>
|
||||
<!-- /post thumbnail -->
|
||||
|
||||
<div class="metadata">
|
||||
<div class="categories">
|
||||
<?php the_category(' | ');?>
|
||||
|
||||
<?php
|
||||
$terms = get_the_terms($post->ID, 'Format');
|
||||
if ($terms) {
|
||||
foreach ($terms as $term) {
|
||||
echo '| ';
|
||||
echo $term->name;
|
||||
}
|
||||
}?>
|
||||
|
||||
</div>
|
||||
<div class="postedon">
|
||||
<?php the_time('Y. m. d.');?>
|
||||
</div>
|
||||
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
<!-- post title -->
|
||||
<h2>
|
||||
<a href="<?php the_permalink();?>" title="<?php the_title();?>"><?php the_title();?></a>
|
||||
</h2>
|
||||
<!-- /post title -->
|
||||
|
||||
|
||||
|
||||
</article>
|
||||
|
||||
|
||||
<?php endwhile;?>
|
||||
|
||||
<?php else: ?>
|
||||
|
||||
<!-- article -->
|
||||
<article>
|
||||
<h2><?php _e('Sorry, nothing to display.', 'dis2019');?></h2>
|
||||
</article>
|
||||
<!-- /article -->
|
||||
|
||||
<?php endif;?>
|
||||
Reference in New Issue
Block a user