<?php
/**
 * The template for displaying Tag pages.
 *
 * Used to display archive-type pages for posts in a tag.
 *
 * Learn more: http://codex.wordpress.org/Template_Hierarchy
 *
 * @package Serpentsoft
 * @subpackage Adams_News 1.0
 * @since Adams News 1.0
 */
get_header(); ?>

<article class="article-container" itemscope itemtype="http://schema.org/Article" role="main">
    <div class="row-fluid">

        <?php if (have_posts()) : ?>

            <div class="article-content">
                <header>
                    <?php serpentsoft_single_breadcrumb(); ?>

                    <h1 itemprop="headline">
                    <?php printf(__('Tag Archives: %s', 'serpentsoft'), '<span>' . single_tag_title('', false) . '</span>'); ?>
                    </h1>

                    <?php if(tag_description()) : // Show an optional tag description ?>
                        <div class="post-info"><small><?php echo tag_description(); ?></small></div>
                    <?php else: ?>
                        <div class="post-info"></div>
                    <?php endif; ?>

                </header>

                <span class="clearfix"></span>

                <!-- Blog Tag -->
                <div class="blog">
                    <ul class="media-list">
                        <?php while (have_posts()) : the_post();
                        get_template_part('loop', 'blog');
                        endwhile; ?>
                    </ul>

                    <div class="row-fluid paging-footer"><?php echo serpentsoft_bootstrap_pagination(); ?></div>

                </div>

            </div> <!-- article-content -->

            <?php else: ?>

            <div class="article-content">
                <header>
                    <?php if(serpentsoft_get_data('serpentsoft_switch_breadcrumb')): ?>
                        <?php if(!empty($get_meta['serpentsoft_post_breadcrumb'][0])):
                            if($get_meta['serpentsoft_post_breadcrumb'][0] != 'hide'): serpentsoft_breadcrumbs(); endif;
                            else: serpentsoft_breadcrumbs(); endif; ?>
                    <?php endif; ?>

                    <h1 itemprop="headline"><?php _e('No Posts Found', 'serpentsoft'); ?></h1>

                    <div class="post-info"></div>

                </header>

                <span class="clearfix"></span>

                <!-- Blog -->
                <div class="blog">
                    <p><?php printf(__('Apologies, but this tag ( %s ) have no posts.', 'serpentsoft'), '<b>' . single_tag_title('', false) . '</b>'); ?></p>
                </div>

            </div>

<?php endif; ?>
    </div>

</article>

<?php get_footer(); ?>