-
Notifications
You must be signed in to change notification settings - Fork 5
/
search.php
50 lines (33 loc) · 1.3 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
42
43
44
45
46
47
48
49
50
<?php
get_header();
$sidebarPosition = get_option('t-side-position');
?>
<div id="main" <?php if ($sidebarPosition == 'right'){ echo 'class="invert"'; } ?>>
<div id="content">
<?php if (have_posts()) : ?>
<div class="morePosts">
<h3>Search results for: <em><?php the_search_query(); ?></em></h3>
<ul <?php $archiveLayout = get_option('t-columns'); if ($archiveLayout == 1){ echo 'class="simpleArchive"'; } ?>>
<?php while (have_posts()) : the_post(); ?>
<li <?php post_class() ?>>
<h4><a href="<?php the_permalink() ?>" rel="bookmark" title="Permanent Link to <?php the_title_attribute(); ?>"><?php the_title(); ?></a></h4>
<span><?php the_time('d M Y'); ?></span>
<p><?php echo get_the_excerpt(); ?></p>
<p><a href="<?php the_permalink() ?>" rel="bookmark" title="Permanent Link to <?php the_title_attribute(); ?>">Continue reading »</a></p>
</li>
<?php endwhile; ?>
</ul>
</div>
<div id="pageNavigation">
<p id="prevPosts"><?php next_posts_link('« Older Articles') ?></p>
<p id="nextPosts"><?php previous_posts_link('Newer Articles »') ?></p>
</div>
<?php else : ?>
<div class="morePosts">
<h3>No posts found. Please try a different search.</h3>
</div>
<?php endif; ?>
</div>
<?php get_sidebar(); ?>
</div>
<?php get_footer(); ?>