-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathsearch.php
More file actions
44 lines (38 loc) · 1.03 KB
/
Copy pathsearch.php
File metadata and controls
44 lines (38 loc) · 1.03 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
<?php
/**
* Template for displaying search results pages.
* Post type: all
*
* @since 0.5.18
*/
// Exits if accessed directly.
if ( ! defined('ABSPATH')) {
exit;
}
// Redirects if search is disabled.
if ( ! apply_filters('bitski-wp-theme/option/header/display-search', true)) {
wp_redirect(home_url());
exit;
}
get_header();
?>
<main id="content" class="content <?php
echo apply_filters('bitski-wp-theme/class/container', ['container-xl'], true); ?> pt-4 pb-5">
<!-- Content header -->
<header class="content-header mb-4">
<h1 class="entry-title"><?php
printf(
esc_html__('Suchergebnisse für: %s', 'bitski-wp-theme'),
'<span class="text-body-secondary">' . get_search_query() . '</span>'
) ?></h1>
</header>
<?php
if (have_posts()) {
get_template_part('templates/pages/search-404/content/results');
} else {
get_template_part('templates/pages/search-404/content/no-results');
}
?>
</main>
<?php
get_footer(); ?>