wordpress/php-fpm/wordpress_files/themes/ltk-foundation/single.php

79 lines
2.1 KiB
PHP
Raw Normal View History

2020-05-22 03:40:23 +02:00
<?php use LTK\Foundation\ViewHelper; ?>
<?php use LTK\Foundation\View\Breadcrumb; ?>
<?php get_header(); ?>
<div class="row">
<div class="<?php ViewHelper::getColumnClass('center'); ?>">
<?php echo Breadcrumb::getBreadcrumb(); ?>
<?php if (have_posts()): while (have_posts()): the_post(); ?>
<article id="post-<?php the_ID(); ?>" <?php post_class(['content-item', 'content-detail']); ?> itemscope itemtype="http://schema.org/Article">
<header class="post-header">
<h2 itemprop="headline">
<a href="<?php the_permalink(); ?>" title="<?php the_title_attribute(); ?>"><?php the_title(); ?></a>
</h2>
<aside class="post-meta">
<span class="post-meta-author">
<?php echo get_avatar(get_the_author_meta('ID'), 20, '', get_the_author_meta('display_name')); ?>
<a href="<?php echo esc_url(get_author_posts_url(get_the_author_meta('ID'))); ?>">
<?php echo esc_html(get_the_author_meta('display_name')); ?>
</a>
</span>
<span class="post-meta-published">
<i class="fa fa-fw fa-clock-o"></i>
<span itemprop="datePublished" content="<?php echo get_the_date('Y-m-d'); ?>"><?php echo get_the_date(); ?></span>
</span>
</aside>
</header>
<div class="post-body" itemprop="articleBody">
<?php if (has_post_thumbnail()): ?>
<div class="thumbnail">
<?php the_post_thumbnail('post-thumbnail', [
'class' => 'img-responsive',
'itemprop' => 'image'
]); ?>
</div>
<?php endif; ?>
<?php the_content(); ?>
<?php wp_link_pages(); ?>
</div>
<aside class="post-footer">
<?php if (has_tag()): ?>
<?php echo get_the_tag_list('<div class="post-tags"><i class="fa fa-fw fa-tag"></i> ', ', ', '</div>'); ?>
<?php endif; ?>
<?php get_template_part('templates/blocks/author'); ?>
<?php comments_template('/templates/comments.php'); ?>
</aside>
</article>
<?php endwhile; endif; ?>
</div>
<?php get_template_part('templates/sidebars/column-left'); ?>
<?php get_template_part('templates/sidebars/column-right'); ?>
</div>
<?php get_footer(); ?>