Advertisement
Guest User

search.php

a guest
Jul 20th, 2011
607
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.73 KB | None | 0 0
  1. <?php
  2. /**
  3. * The template for displaying Search Results pages.
  4. *
  5. * @package WordPress
  6. * @subpackage Twenty_Eleven
  7. * @since Twenty Eleven 1.0
  8. */
  9.  
  10. get_header(); ?>
  11.  
  12. <div id="infobar"></div>
  13.  
  14. </div>
  15.  
  16. <div id="hc-content"><div class="datablock">
  17. <section id="primary">
  18. <div id="content" role="main">
  19.  
  20. <?php if ( have_posts() ) : ?>
  21.  
  22. <header class="page-header">
  23. <h1 class="page-title"><?php printf( __( 'Search Results for: %s', 'twentyeleven' ), '<span>' . get_search_query() . '</span>' ); ?></h1>
  24. </header>
  25.  
  26. <?php twentyeleven_content_nav( 'nav-above' ); ?>
  27.  
  28. <?php /* Start the Loop */ ?>
  29. <?php while ( have_posts() ) : the_post(); ?>
  30.  
  31. <?php
  32. /* Include the Post-Format-specific template for the content.
  33. * If you want to overload this in a child theme then include a file
  34. * called content-___.php (where ___ is the Post Format name) and that will be used instead.
  35. */
  36. get_template_part( 'content', get_post_format() );
  37. ?>
  38.  
  39. <?php endwhile; ?>
  40.  
  41. <?php twentyeleven_content_nav( 'nav-below' ); ?>
  42.  
  43. <?php else : ?>
  44.  
  45. <article id="post-0" class="post no-results not-found">
  46. <header class="entry-header">
  47. <h1 class="entry-title"><?php _e( 'Nothing Found', 'twentyeleven' ); ?></h1>
  48. </header><!-- .entry-header -->
  49.  
  50. <div class="entry-content">
  51. <p><?php _e( 'Sorry, but nothing matched your search criteria. Please try again with some different keywords.', 'twentyeleven' ); ?></p>
  52. <?php get_search_form(); ?>
  53. </div><!-- .entry-content -->
  54. </article><!-- #post-0 -->
  55.  
  56. <?php endif; ?>
  57.  
  58. </div><!-- #content -->
  59. </section><!-- #primary -->
  60.  
  61. </div></div>
  62.  
  63. <?php get_footer(); ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement