-
Notifications
You must be signed in to change notification settings - Fork 0
/
search.php
41 lines (36 loc) · 1.31 KB
/
search.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
<?php get_header(); ?>
<div id="content" class="search">
<h1><?php the_search_query(); ?></h1>
<?php if (have_posts()) : while (have_posts()) : the_post(); ?>
<div class="single-post">
<h2><a href="<?php the_permalink() ?>" title="<?php the_title(); ?>" rel="bookmark"><?php the_title(); ?></a></h2>
<?php echo '<div class="featuredThumbnail">'; the_post_thumbnail(); echo '</div>'; /* loades the post's featured thumbnail, requires Wordpress 3.0+ */ ?>
<p>
Written on <?php the_time('F j, Y'); ?>, by <?php the_author_posts_link() ?>
</p>
<div class="post-excerpt">
<?php the_excerpt(); /* the excerpt is loaded to help avoid duplicate content issues */ ?>
</div><!--.post-excerpt-->
</div><!--.single-post-->
<?php endwhile; else: ?>
<div class="no-results">
<h2>No Results</h2>
<p>Please feel free try again!</p>
<?php get_search_form(); /* outputs the default Wordpress search form */ ?>
</div><!--no-results-->
<?php endif; ?>
<nav class="oldernewer">
<div class="older">
<p>
<?php next_posts_link('« Older Entries') ?>
</p>
</div><!--.older-->
<div class="newer">
<p>
<?php previous_posts_link('Newer Entries »') ?>
</p>
</div><!--.older-->
</nav><!--.oldernewer-->
</div><!-- #content -->
<?php get_sidebar(); ?>
<?php get_footer(); ?>