Files
Bookshelf/bd-bookshelf/search.php
2026-10-18 19:01:01 -07:00

53 lines
1.3 KiB
PHP

<?php
// Copyright 2026 Umbra Tools (umbratools.com)
// SPDX-License-Identifier: Apache-2.0
/**
* Template Name: Search Results
*
* @package BD_Murphy
*/
get_header();
?>
<div class="search-container">
<header class="page-header">
<h1 class="page-title">
<?php
printf(
esc_html__('Search Results for: %s', 'bd-bookshelf'),
'<span>' . esc_html(get_search_query()) . '</span>'
);
?>
</h1>
</header>
<div class="search-results">
<?php
if (have_posts()) :
while (have_posts()) :
the_post();
?>
<article id="post-<?php the_ID(); ?>" <?php post_class('search-entry'); ?>>
<h2 class="search-entry-title">
<a href="<?php the_permalink(); ?>"><?php the_title(); ?></a>
</h2>
<div class="search-entry-excerpt">
<?php the_excerpt(); ?>
</div>
</article>
<?php
endwhile;
else :
?>
<p class="no-results">
<?php esc_html_e('No results found. Please try a different search.', 'bd-bookshelf'); ?>
</p>
<?php endif; ?>
</div>
</div>
<?php
get_footer();