This repository has been archived on 2020-05-08. You can view files and clone it, but cannot push or open issues or pull requests.
_s/search.php

46 lines
1.1 KiB
PHP
Raw Normal View History

2012-01-07 03:25:13 +00:00
<?php
/**
* The template for displaying search results pages.
2012-01-07 03:25:13 +00:00
*
* @package _s
*/
get_header(); ?>
<section id="primary" class="content-area">
<main id="main" class="site-main" role="main">
2012-01-07 03:25:13 +00:00
<?php if ( have_posts() ) : ?>
2012-01-07 03:25:13 +00:00
<header class="page-header">
<h1 class="page-title"><?php printf( esc_html__( 'Search Results for: %s', '_s' ), '<span>' . get_search_query() . '</span>' ); ?></h1>
</header><!-- .page-header -->
2012-01-07 03:25:13 +00:00
<?php /* Start the Loop */ ?>
<?php while ( have_posts() ) : the_post(); ?>
2012-01-07 03:25:13 +00:00
<?php
/**
* Run the loop for the search to output the results.
* If you want to overload this in a child theme then include a file
* called content-search.php and that will be used instead.
*/
get_template_part( 'template-parts/content', 'search' );
?>
2012-01-07 03:25:13 +00:00
<?php endwhile; ?>
2012-01-07 03:25:13 +00:00
<?php the_posts_navigation(); ?>
2012-01-07 03:25:13 +00:00
<?php else : ?>
2012-01-07 03:25:13 +00:00
<?php get_template_part( 'template-parts/content', 'none' ); ?>
2012-01-07 03:25:13 +00:00
<?php endif; ?>
2012-01-07 03:25:13 +00:00
</main><!-- #main -->
</section><!-- #primary -->
2012-01-07 03:25:13 +00:00
<?php get_sidebar(); ?>
<?php get_footer(); ?>