-
Notifications
You must be signed in to change notification settings - Fork 0
/
search.php
57 lines (43 loc) · 1.39 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
<?php get_header(); ?>
<?php if ( have_posts() ) : ?>
<div class="row">
<div class="span12">
<h1 class="page-title"><?php printf( __( 'Search Results for: %s', 'twentyeleven' ), '<em>' . get_search_query() . '</em>' ); ?></h1>
</div>
</div>
<hr />
<?php while ( have_posts() ) : the_post(); ?>
<div class="row">
<div class="span12">
<h3><a href="<?php the_permalink() ?>" rel="bookmark" title="Permanent Link to <?php the_title_attribute(); ?>"><?php search_title_highlight(); ?></a></h3>
</div>
</div>
<div class="row">
<div class="span12">
<?php search_content_highlight(); ?>
</div>
</div>
<hr />
<?php endwhile; else: ?>
<div class="row">
<div class="span12">
<h1 class="page-title">Sorry, nothing found.</h1>
</div>
</div>
<div class="row">
<div class="span4">
<form class="form" id="popup-search" action="<?php echo site_url('/'); ?>">
<div class="input-append">
<input type="text" class="span2" name="s" id="s" <?php if(isset($_GET['s'])){
echo "value=\"".$_GET['s']."\"";
} ?>>
<button type="submit" class="btn">Search</button>
</div>
</form>
</div>
<div class="span8">
<p>Please try again with some different keywords.</p>
</div>
</div>
<?php endif; ?>
<?php get_footer(); ?>