<?php get_header(); 
$dannci_redux = get_option( 'dannci_redux' );?>

<div class="dnnc_page_header">

<?php if(empty($dannci_redux['dnnc-header-image']['url'])) {} else { ?>
    
        <img class="dnnc_head_img" src="<?php echo esc_url($dannci_redux['dnnc-header-image']['url']);?>" alt="<?php the_title_attribute(); ?>"/>
        
<?php }  ?>
  
</div>

<?php 	
	$dannci_redux = get_option( 'dannci_redux' );
	if (!empty($dannci_redux['dnnc-blog-layout'])) {
		$dannci_blog_layout = $dannci_redux['dnnc-blog-layout']; 
	}
?>
    
<div class="dnnc_container <?php if (empty($dannci_redux['dnnc-blog-layout'])) {} else {
	if($dannci_blog_layout == 'dnnc_blogger_full_width'){
			echo 'archive_full_width';
		} else {
			echo '';
	}
} ?>">

    <div class="dnnc_column dnnc_column_12">
    
        <?php if (is_category()) { ?>
            <h1 class="archive_title large_title dnnc_border"><span class="dnnc_maintitle"><?php single_cat_title(); ?></span>
            <span class="dnnc_archive_subtitle medium_title"><?php echo strip_tags(category_description()); ?> </span></h1> 
    
        <?php } elseif (is_day()) { ?>
        
            <h1 class="archive_title large_title dnnc_border"><span class="dnnc_maintitle"><?php the_time( get_option( 'date_format' ) ); ?></span>
            <span class="dnnc_archive_subtitle medium_title"><?php esc_html_e('Archive','arstad');?></span></h1>  

        <?php } elseif (is_month()) { ?>
        
            <h1 class="archive_title large_title dnnc_border"><span class="dnnc_maintitle"><?php the_time( 'F, Y' ); ?></span>
            <span class="dnnc_archive_subtitle medium_title"><?php esc_html_e('Archive','arstad');?></span></h1>  

        <?php } elseif (is_year()) { ?>
        
            <h1 class="archive_title large_title dnnc_border"><span class="dnnc_maintitle"><?php the_time( 'Y' ); ?></span>
            <span class="dnnc_archive_subtitle medium_title"><?php esc_html_e('Archive','arstad');?></span></h1>  

        <?php } elseif (is_author()) { ?>
        
            <h1 class="archive_title large_title dnnc_border"><span class="dnnc_maintitle"><?php  $curauth = (isset($_GET['author_name'])) ? get_user_by('slug', $author_name) : get_userdata(intval($author)); echo esc_attr($curauth->nickname);?></span>
            <span class="dnnc_archive_subtitle medium_title"><?php echo esc_attr($curauth->user_description); ?></span></h1>
            
        <?php } elseif (is_tag()) { ?>
        
            <h1 class="archive_title large_title dnnc_border"><span class="dnnc_maintitle"><?php echo single_tag_title( '', true); ?></span>
            <span class="dnnc_archive_subtitle medium_title"><?php esc_html_e('Tag Archive','arstad');?></span></h1>  
        
        <?php } ?>
            
    </div><!-- end .dnnc_column_12  -->
    
</div><!-- end .dnnc_container  -->
	



<div class="dnnc_container dnnc_blogger_archive 
<?php if (empty($dannci_redux['dnnc-blog-layout'])) {echo 'dnnc_blogger_sidebar';} else {
	if($dannci_blog_layout == 'dnnc_blogger_sidebar'){
			echo 'dnnc_blogger_sidebar';
		}elseif($dannci_blog_layout == 'dnnc_blogger_full_width'){
			echo 'dnnc_blogger_full_width';
		} else {
			echo 'dnnc_blogger_sidebar';
	}
} ?>">

    <div id="content_start" class="dnnc_anchor"></div>

    <div id="content" class="dnnc_column dnnc_content">
                
        <div class="dnnc_blogger dnnc_columns_wrap">
        
            <?php if (have_posts()) : ?>
                                
            <?php while (have_posts()) : the_post();?>
            
				<div class="item dnnc_column dnnc_column_12">
				
				<?php if(has_post_format('quote')){get_template_part('/post-types/post-quote-index');} 
				  
				  else {
				
					  get_template_part('/post-types/post-classic');
					  
				  } ?>
				  
				</div>
                    
            <?php endwhile; ?><!-- end post -->
            
            <div class="clearfix"></div>
                
        </div><!-- end latest posts section-->
          
          <div class="clearfix"></div>
    
          <div class="pagination"><?php the_posts_pagination(); ?></div>

          <?php else : ?>
  

                  <div class="errorentry entry">
      
                      <h1 class="post entry-title" itemprop="headline"><?php esc_html_e('Nothing found here','arstad');?></h1>
                  
                      <h4><?php esc_html_e('Perhaps You will find something interesting from these lists...','arstad');?></h4>
                  
                      <div class="hrline"></div>
                  
                      <?php get_template_part('/includes/uni-404-content');?>
                  
                  </div>
              
              </div><!-- end latest posts section-->
              
          <?php endif; ?>               
    
      </div><!-- end #content -->
      
      <?php if (empty($dannci_redux['dnnc-blog-layout'])) {echo '';} else {
            if($dannci_blog_layout == 'dnnc_blogger_sidebar'){
                    get_sidebar(); 
            }
		} ?>
      
      <div class="clearfix"></div>
            
    </div><!-- end #content -->
    
</div><!-- end .dnnc_container -->

<div class="clearfix"></div>

<?php get_footer(); ?>