<?php
/**
 * The template for displaying Category pages
 *
 * @package Krown
 * @subpackage Krown
 * @since Krown 1.0
 */
?>
<?php get_template_part( 'single', 'header' ); ?>
<?php get_template_part( 'top', 'menu' );?>

<section id="blog" class="section">
	<?php if ( have_posts() ) : ?>
	<div class="page-title">
		<h2><?php printf( __( 'Tag Archives: %s', 'krwn' ), single_tag_title( '', false ) ); ?></h2>
	</div>
	
	<div class="container">
		<div class="content-blog">
			<?php
				while ( have_posts() ) : the_post();
			?>
			<div class="blog-item">
				<div class="blog-title">
					<a href="<?php the_permalink();?>">
						<h2><?php echo get_the_title();?></h2>
					</a>
				</div>
				<p class="blog-descript">
					<?php echo substr(get_the_content(), 0, 300);?>
				</p>
				<div class="blog-info">
					posted by <?php echo get_the_author();?> on <?php echo get_the_time('F'); ?> <?php echo get_the_time('j'); ?>, <?php echo get_the_time('Y'); ?> in design / <?php get_comments_number(); ?> comments
				</div>
			</div>
			<?php endwhile;?>
		</div>
	</div>
	<?php 
	else :
		// If no content, include the "No posts found" template.
		get_template_part( 'content', 'none' );
	endif;
	?>
</section>
<?php
get_footer();