Browse Source

old theme

windhamdavid 6 years ago
parent
commit
c1371277b4
5 changed files with 296 additions and 0 deletions
  1. 32 0
      404.php
  2. 74 0
      archive.php
  3. 74 0
      author.php
  4. 58 0
      blog.php
  5. 58 0
      category.php

+ 32 - 0
404.php

@@ -0,0 +1,32 @@
+<?php
+/**
+ * The template for displaying 404 pages (Not Found)
+ *
+ * @package WordPress
+ * @subpackage Twenty_Fourteen
+ * @since Twenty Fourteen 1.0
+ */
+
+get_header(); ?>
+
+
+	<div id="primary" class="content-area">
+		<div id="content" class="site-content" role="main">
+
+			<header class="page-header">
+				<h1 class="page-title"><?php _e( 'Not Found', 'twentyfourteen' ); ?></h1>
+			</header>
+
+			<div class="page-content">
+				<p><?php _e( 'It looks like nothing was found at this location. Maybe try a search?', 'twentyfourteen' ); ?></p>
+
+				<?php get_search_form(); ?>
+			</div><!-- .page-content -->
+
+		</div><!-- #content -->
+	</div><!-- #primary -->
+
+<?php
+get_sidebar( 'content' );
+get_sidebar();
+get_footer();

+ 74 - 0
archive.php

@@ -0,0 +1,74 @@
+<?php
+/**
+ * The template for displaying Archive pages
+ *
+ * Used to display archive-type pages if nothing more specific matches a query.
+ * For example, puts together date-based pages if no date.php file exists.
+ *
+ * If you'd like to further customize these archive views, you may create a
+ * new template file for each specific one. For example, Twenty Fourteen
+ * already has tag.php for Tag archives, category.php for Category archives,
+ * and author.php for Author archives.
+ *
+ * @link http://codex.wordpress.org/Template_Hierarchy
+ *
+ * @package WordPress
+ * @subpackage Twenty_Fourteen
+ * @since Twenty Fourteen 1.0
+ */
+
+get_header(); ?>
+
+	<section id="primary" class="content-area">
+		<div id="content" class="site-content" role="main">
+
+			<?php if ( have_posts() ) : ?>
+
+			<header class="page-header">
+				<h1 class="page-title">
+					<?php
+						if ( is_day() ) :
+							printf( __( 'Daily Archives: %s', 'twentyfourteen' ), get_the_date() );
+
+						elseif ( is_month() ) :
+							printf( __( 'Monthly Archives: %s', 'twentyfourteen' ), get_the_date( _x( 'F Y', 'monthly archives date format', 'twentyfourteen' ) ) );
+
+						elseif ( is_year() ) :
+							printf( __( 'Yearly Archives: %s', 'twentyfourteen' ), get_the_date( _x( 'Y', 'yearly archives date format', 'twentyfourteen' ) ) );
+
+						else :
+							_e( 'Archives', 'twentyfourteen' );
+
+						endif;
+					?>
+				</h1>
+			</header><!-- .page-header -->
+
+			<?php
+					// Start the Loop.
+					while ( have_posts() ) : the_post();
+
+						/*
+						 * Include the post format-specific template for the content. If you want to
+						 * use this in a child theme, then include a file called called content-___.php
+						 * (where ___ is the post format) and that will be used instead.
+						 */
+						get_template_part( 'content', get_post_format() );
+
+					endwhile;
+					// Previous/next page navigation.
+					if (function_exists("pagination")) : pagination(); endif;
+
+				else :
+					// If no content, include the "No posts found" template.
+					get_template_part( 'content', 'none' );
+
+				endif;
+			?>
+		</div><!-- #content -->
+	</section><!-- #primary -->
+
+<?php
+get_sidebar( 'content' );
+get_sidebar();
+get_footer();

+ 74 - 0
author.php

@@ -0,0 +1,74 @@
+<?php
+/**
+ * The template for displaying Author archive pages
+ *
+ * @link http://codex.wordpress.org/Template_Hierarchy
+ *
+ * @package WordPress
+ * @subpackage Twenty_Fourteen
+ * @since Twenty Fourteen 1.0
+ */
+
+get_header(); ?>
+
+	<section id="primary" class="content-area">
+		<div id="content" class="site-content" role="main">
+
+			<?php if ( have_posts() ) : ?>
+
+			<header class="archive-header">
+				<h1 class="archive-title">
+					<?php
+						/*
+						 * Queue the first post, that way we know what author
+						 * we're dealing with (if that is the case).
+						 *
+						 * We reset this later so we can run the loop properly
+						 * with a call to rewind_posts().
+						 */
+						the_post();
+
+						printf( __( 'All posts by %s', 'twentyfourteen' ), get_the_author() );
+					?>
+				</h1>
+				<?php if ( get_the_author_meta( 'description' ) ) : ?>
+				<div class="author-description"><?php the_author_meta( 'description' ); ?></div>
+				<?php endif; ?>
+			</header><!-- .archive-header -->
+
+			<?php
+					/*
+					 * Since we called the_post() above, we need to rewind
+					 * the loop back to the beginning that way we can run
+					 * the loop properly, in full.
+					 */
+					rewind_posts();
+
+					// Start the Loop.
+					while ( have_posts() ) : the_post();
+
+						/*
+						 * Include the post format-specific template for the content. If you want to
+						 * use this in a child theme, then include a file called called content-___.php
+						 * (where ___ is the post format) and that will be used instead.
+						 */
+						get_template_part( 'content', get_post_format() );
+
+					endwhile;
+					// Previous/next page navigation.
+					if (function_exists("pagination")) : pagination(); endif;
+
+				else :
+					// If no content, include the "No posts found" template.
+					get_template_part( 'content', 'none' );
+
+				endif;
+			?>
+
+		</div><!-- #content -->
+	</section><!-- #primary -->
+
+<?php
+get_sidebar( 'content' );
+get_sidebar();
+get_footer();

+ 58 - 0
blog.php

@@ -0,0 +1,58 @@
+<?php
+/*
+Template Name: Blog Template
+*/
+?>
+<?php
+
+
+get_header(); ?>
+
+<div id="main-content" class="main-content inner-wrapper">
+	<div id="primary" class="content-area">
+		<div id="content" class="site-content" role="main">
+			<?php	 		 		 	 if(have_posts()): ?>
+       <?php
+$temp = $wp_query;
+$wp_query= null;
+$wp_query = new WP_Query();
+$wp_query->query('posts_per_page=5'.'&paged='.$paged);
+while ($wp_query->have_posts()) : $wp_query->the_post();
+?>
+        
+			
+			
+				<a href="<?php	 		 		 	 the_permalink() ?>"><h2><?php	 		 		 	 the_title() ?></h2></a>
+				<?php	 		 		 	 the_content() ?>
+				<?php	 		 		 	 if(is_page() or is_single()): ?>
+				<?php	 		 		 	 the_content() ?>
+				<?php $wp_query = null; $wp_query = $temp;?>
+				<p class="small">Posted by <a href="<?php	 		 		 	 the_author_meta('user_url'); ?>"><?php	 		 		 	 the_author() ?></a> on <?php	 		 		 	 the_date() ?>, at <?php	 		 		 	 the_time() ?></p>
+				<a href="<?php	 		 		 	 the_permalink() ?>" class="left"><?php	 		 		 	 the_post_thumbnail('thumbnail'); ?></a> 
+				<?php	 		 		 	 the_excerpt() ?>
+				<p><a href="<?php	 		 		 	 the_permalink() ?>">Read More &rarr;</a></p>
+				<?php	 		 		 	 endif ?>
+				<div class="clear"></div>
+				<div class="meta"><?php	 		 		 	 _e("FILED UNDER:"); ?> <?php	 		 		 	 the_category(',') ?><br />
+				<?php	 		 		 	 the_tags(__('TAGGED AS: '), ', ', ''); ?> 
+				<p><?php	 		 		 	 edit_post_link(__('Edit This')); ?></p>
+				</div>
+				<div class="feedback">
+					<?php	 		 		 	 wp_link_pages(); ?>
+					<?php	 		 		 	 comments_popup_link(__('Comments (0)'), __('Comments (1)'), __('Comments (%)')); ?>
+				</div>
+				<?php	 		 		 	 comments_template(); // Get wp-comments.php template ?>
+			
+		<hr />
+        <?php	 		 		 	 endwhile ?>
+        <?php	 		 		 	 endif ?>
+ <div id="clear"></div>
+		</div><!-- #content -->
+	</div><!-- #primary -->
+</div><!-- #main-content -->
+
+
+
+
+
+<?php get_footer(); ?>

+ 58 - 0
category.php

@@ -0,0 +1,58 @@
+<?php
+/**
+ * The template for displaying Category pages
+ *
+ * @link http://codex.wordpress.org/Template_Hierarchy
+ *
+ * @package WordPress
+ * @subpackage Twenty_Fourteen
+ * @since Twenty Fourteen 1.0
+ */
+
+get_header(); ?>
+
+	<section id="primary" class="content-area">
+		<div id="content" class="site-content" role="main">
+
+			<?php if ( have_posts() ) : ?>
+
+			<header class="archive-header">
+				<h1 class="archive-title"><?php printf( __( 'Category Archives: %s', 'twentyfourteen' ), single_cat_title( '', false ) ); ?></h1>
+
+				<?php
+					// Show an optional term description.
+					$term_description = term_description();
+					if ( ! empty( $term_description ) ) :
+						printf( '<div class="taxonomy-description">%s</div>', $term_description );
+					endif;
+				?>
+			</header><!-- .archive-header -->
+
+			<?php
+					// Start the Loop.
+					while ( have_posts() ) : the_post();
+
+					/*
+					 * Include the post format-specific template for the content. If you want to
+					 * use this in a child theme, then include a file called called content-___.php
+					 * (where ___ is the post format) and that will be used instead.
+					 */
+					get_template_part( 'content', get_post_format() );
+
+					endwhile;
+					// Previous/next page navigation.
+					if (function_exists("pagination")) : pagination(); endif;
+
+				else :
+					// If no content, include the "No posts found" template.
+					get_template_part( 'content', 'none' );
+
+				endif;
+			?>
+		</div><!-- #content -->
+	</section><!-- #primary -->
+
+<?php
+get_sidebar( 'content' );
+get_sidebar();
+get_footer();