-
Notifications
You must be signed in to change notification settings - Fork 1
/
search.php
66 lines (34 loc) · 1.78 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
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
<?php theme_include('header'); ?>
<!-- SEARCH DON'T WORK NOW. IN NEXT UPDATE MAYBE... -->
<div class="container">
<div class="posts">
<div class="row-fluid">
<div class="span12">
<h2>You searched for “<?php echo search_term(); ?>”.</h1>
<p>We found <?php echo total_search_results(); ?> <?php echo pluralise(total_search_results(), 'result'); ?> for “<?php echo search_term(); ?>”. See it below.</p>
</div>
</div>
<?php if(has_search_results()): ?>
<div class="row-fluid">
<?php while(search_results()): ?>
<div class="span12">
<h2><a href="<?php echo article_url(); ?>"> <?php echo article_title(); ?></a></h2>
<p><?php echo article_markdown(); ?></p>
<div class="and"><?php echo article_author('real_name'); ?> & <?php echo relative_time(article_time()); ?></div>
</div>
<?php endwhile; ?>
<div class="pagination" style="text-align:center;margin:15px;font-size:20px;">
<div class="wrap">
<?php echo posts_next('← Newest'); ?>
<?php echo posts_prev('Oldest →'); ?>
</div>
</div>
<?php else: ?>
<div class="span12">
<h2>Looks like you have some writing to do!</h2>
</div>
<?php endif; ?>
</div>
</div>
</div>
<?php theme_include('footer'); ?>