-
Notifications
You must be signed in to change notification settings - Fork 0
/
search.php
38 lines (30 loc) · 804 Bytes
/
search.php
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
<?php
/**
* The template for displaying Search Results pages.
*
* @since 3.0.0
*/
get_header(); ?>
<section id="primary" <?php mb_primary_attr(); ?> role="main">
<?php if ( have_posts() ) : ?>
<h1 id="search-header" class="page-title"><?php
global $wp_query;
$num = $wp_query->found_posts;
printf( '%1$s "%2$s"',
$num . __( ' search results for', 'magazine-basic'),
get_search_query()
);
?></h1>
<?php
while ( have_posts() ) : the_post();
global $mb_content_area;
$mb_content_area = 'main';
get_template_part( 'content', get_post_format() );
endwhile;
mb_pagination();
else :
get_template_part( 'content', 'none' );
endif; // end current_user_can() check
?>
</section><!-- #primary.c8 -->
<?php get_footer(); ?>