Wordpress 3.5
[autoinstalls/wordpress.git] / wp-content / themes / twentytwelve / search.php
1 <?php
2 /**
3  * The template for displaying Search Results pages.
4  *
5  * @package WordPress
6  * @subpackage Twenty_Twelve
7  * @since Twenty Twelve 1.0
8  */
9
10 get_header(); ?>
11
12         <section id="primary" class="site-content">
13                 <div id="content" role="main">
14
15                 <?php if ( have_posts() ) : ?>
16
17                         <header class="page-header">
18                                 <h1 class="page-title"><?php printf( __( 'Search Results for: %s', 'twentytwelve' ), '<span>' . get_search_query() . '</span>' ); ?></h1>
19                         </header>
20
21                         <?php twentytwelve_content_nav( 'nav-above' ); ?>
22
23                         <?php /* Start the Loop */ ?>
24                         <?php while ( have_posts() ) : the_post(); ?>
25                                 <?php get_template_part( 'content', get_post_format() ); ?>
26                         <?php endwhile; ?>
27
28                         <?php twentytwelve_content_nav( 'nav-below' ); ?>
29
30                 <?php else : ?>
31
32                         <article id="post-0" class="post no-results not-found">
33                                 <header class="entry-header">
34                                         <h1 class="entry-title"><?php _e( 'Nothing Found', 'twentytwelve' ); ?></h1>
35                                 </header>
36
37                                 <div class="entry-content">
38                                         <p><?php _e( 'Sorry, but nothing matched your search criteria. Please try again with some different keywords.', 'twentytwelve' ); ?></p>
39                                         <?php get_search_form(); ?>
40                                 </div><!-- .entry-content -->
41                         </article><!-- #post-0 -->
42
43                 <?php endif; ?>
44
45                 </div><!-- #content -->
46         </section><!-- #primary -->
47
48 <?php get_sidebar(); ?>
49 <?php get_footer(); ?>