Make WordPress Themes

source: multisport/1.5.0/search.php

Last change on this file was 139039, checked in by themedropbox, 5 years ago

New version of MultiSport - 1.3.9

File size: 1.0 KB
Line 
1<?php
2/**
3 * The template for displaying search results pages.
4 */
5
6 get_header(); ?>
7
8<div id="main-content-wrapper">
9
10        <div id="main-content">
11
12                <div id="infoTxt">
13                        <?php 
14                                /* translators: %s: search query */
15                                printf( esc_html__( 'You searched for "%s". Here are the results:', 'multisport' ),
16                                                get_search_query() );
17                        ?>
18                </div><!-- #infoTxt -->
19
20        <?php if ( have_posts() ) :
21
22                                // starts the loop
23                                while ( have_posts() ) :
24
25                                        the_post();
26
27                                        /**
28                                         * Run the loop for the search to output the results.
29                                         */
30                                        get_template_part( 'template-parts/content', 'excerpt' );
31
32                                endwhile;
33       
34                                the_posts_pagination( array(
35                                        'prev_next' => '',
36                                    ) );
37
38                else :
39
40                                // if no content is loaded, show the 'no found' template
41                                get_template_part( 'template-parts/content', 'none' );
42                       
43                  endif;
44        ?>
45
46        </div><!-- #main-content -->
47
48        <?php get_sidebar(); ?>
49
50</div><!-- #main-content-wrapper -->
51
52<?php get_footer(); ?>
Note: See TracBrowser for help on using the repository browser.