A WordPress theme I used to use on www.chriswiegman.com.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
This repo is archived. You can view files and clone it, but cannot push or open issues/pull-requests.
 
 
 
 
 
 

57 lines
1.0 KiB

  1. <?php
  2. /**
  3. * The template for the search results page
  4. *
  5. * @since 5.0.0
  6. *
  7. * @package CW\Theme\Templates\Search
  8. *
  9. * @author Chris Wiegman <chris@chriswiegman.com>
  10. */
  11. namespace CW\Theme\Templates\Search;
  12. use CW\Theme\Functions\Template_Tags;
  13. get_header();
  14. ?>
  15. <section id="primary" class="content-area">
  16. <main id="main" class="site-main" role="main">
  17. <?php
  18. if ( have_posts() ) {
  19. ?>
  20. <header class="page-header">
  21. <?php // translators: search query. ?>
  22. <h1 class="page-title"><?php printf( esc_html__( 'Search Results for: %s', 'chriswiegman' ), '<span>' . esc_html( get_search_query() ) . '</span>' ); ?></h1>
  23. </header><!-- .page-header -->
  24. <?php
  25. /* Start the Loop */
  26. while ( have_posts() ) {
  27. the_post();
  28. get_template_part( 'template-parts/content' );
  29. }
  30. Template_Tags\paging_nav();
  31. } else {
  32. get_template_part( 'template-parts/content', 'none' );
  33. }
  34. ?>
  35. </main><!-- #main -->
  36. </section><!-- #primary -->
  37. <?php
  38. get_sidebar();
  39. get_footer();