Browse Source

archive pages

windhamdavid 8 years ago
parent
commit
30e0bd11c6
4 changed files with 82 additions and 22 deletions
  1. 48 17
      archive.php
  2. 5 2
      category.php
  3. 29 3
      style.css
  4. 0 0
      style.min.css

+ 48 - 17
archive.php

@@ -3,25 +3,56 @@
 	<div class="container">
 		<div id="content" role="main">
 			<div class="entry-content archive">
-				<?php if ( have_posts() ) : ?>
-				<header class="page-header">
-					<h1 class="super cm-sans wow fadeInLeft">Archive: <?php the_time('Y'); ?></h1>
-				</header>
-				<?php while ( have_posts() ) : the_post();?>
-				<h1 class="entry-title"><a href="<?php the_permalink(); ?>" title="<?php printf( esc_attr__( 'Permalink to %s', 'dw' ), the_title_attribute( 'echo=0' ) ); ?>" rel="bookmark"><?php the_title(); ?></a></h1>
-				<div class="entry-meta">
-					<div class="date">
-						<?php the_date(); ?>
+				<div class="row">					
+					<?php if ( have_posts() ) : ?>
+					<header class="page-header">
+						<h1 class="super cm-sans wow fadeInRight"><?php the_time('Y'); ?></h1>
+					</header>
+					<?php while ( have_posts() ) : the_post();?>
+					
+					<div class="col-sm-6">
+						<div class="single-card">
+							<h1 class="entry-title"><a href="<?php the_permalink(); ?>" title="<?php printf( esc_attr__( 'Permalink to %s', 'dw' ), the_title_attribute( 'echo=0' ) ); ?>" rel="bookmark"><?php the_title(); ?></a></h1>
+							<div class="entry-meta">
+								<div class="date">
+									<?php the_date(); ?>
+								</div>
+							</div>
+							<div class="single-card-thumbnail">
+								<?php if ( has_post_thumbnail() ) : ?>
+								    <a href="<?php the_permalink(); ?>" title="<?php the_title_attribute(); ?>">
+								        <?php the_post_thumbnail( 'thumbnail', array( 'class' => 'alignleft' ) ); ?>
+								    </a>
+								<?php endif; ?>
+							</div>
+							<?php the_excerpt(); ?>
+						</div>
+					</div>
+		
+					<?php endwhile;
+						dw_paging_nav();
+					else :
+						printf( __( 'Nothing Found', 'dw' ));		
+						get_search_form();
+					endif;
+					?>	
+				</div>
+				<div class="clear">&nbsp;</div>
+				<div class="row">
+					<div id="nav-below" class="navigation">
+						<?php 		
+							$archive_year = get_the_date('U');
+							$old_archive = date("Y",strtotime('-1 year', $archive_year));
+							$new_archive = date("Y",strtotime('+1 year', $archive_year));
+						?>
+						<div class="nav-previous">
+							&larr; <a href="<?php echo get_year_link( $old_archive ); ?>"><?php echo $old_archive ?></a>
+						</div>
+						<div class="nav-next">
+							<a href="<?php echo get_year_link( $new_archive ); ?>"><?php echo $new_archive ?></a> &rarr;
+						</div>
 					</div>
 				</div>
-				<?php dw_good_excerpt(110); ?>
-				<?php endwhile;
-					dw_paging_nav();
-				else :
-					printf( __( 'Nothing Found', 'dw' ));		
-					get_search_form();
-				endif;
-				?>
 			</div>
 		</div>
 	</div>

+ 5 - 2
category.php

@@ -14,8 +14,11 @@
 					</div>
 				</div>
 				<?php the_excerpt(); ?>
-				<?php endwhile;
-					dw_paging_nav();
+				<?php endwhile; ?>
+				
+				<div class="clear">&nbsp;</div>
+				<hr>
+				<?php dw_paging_nav();
 				else :
 					printf( __( 'Nothing Found', 'dw' ));		
 					get_search_form();

+ 29 - 3
style.css

@@ -1836,13 +1836,13 @@ div#player{
 }	
 .nav-previous span.meta-nav {
 	color: #888;
-	font-size: 12px;
+	font-size: 14px;
 	font-style: italic;
 	font-weight: normal;
 }
 .nav-next span.meta-nav {
 	color: #888;
-	font-size: 12px;
+	font-size: 14px;
 	font-style: italic;
 	font-weight: normal;
 }
@@ -2038,6 +2038,26 @@ body.page .edit-link {
 	border-bottom-left-radius:0;
 }
 
+.archive {
+	background:#fff;
+	box-shadow: 0 0 5px rgba(0,0,0,.1);
+	padding: 70px 100px 140px;
+}
+.single-card {
+	border: 1px solid #eee;
+	padding:10px 15px;
+	margin:10px 0 10px;
+	min-height: 230px;
+}
+.single-card:hover{
+    background-color: rgba(0, 0, 0, 0.1);
+}
+.single-card .entry-title {
+	margin-bottom:5px !important;
+}
+.single-card-thumbnail img {
+	border:5px solid #cecece;
+}
 
 /*============================================
 		Meta 
@@ -2491,11 +2511,13 @@ img.me {
 	color: #ff4b33;
 }
 .nav-previous {
+	font-size:14px;
 	float: left;
 	width: 50%;
 	margin: 0 0 15px 0;
 }
 .nav-next {
+	font-size:14px;
 	float: right;
 	text-align: right;
 	width: 50%;
@@ -2517,7 +2539,6 @@ img.me {
 }
 .pagination {
 	margin-top: 40px;
-	border-top: 1px solid #cecece;
 	padding: 20px 0 0;
 }
 .pagination a {
@@ -2550,6 +2571,11 @@ img.me {
 	font-weight: bold;
 	font-size: 16px;
 }
+.page-numbers {
+	padding: 4px 5px;
+	font-weight: bold;
+	font-size: 16px;
+}
 
 
 /*============================================

File diff suppressed because it is too large
+ 0 - 0
style.min.css


Some files were not shown because too many files changed in this diff