1 | <?php |
||
2 | /** |
||
3 | * The template for displaying Search Results pages. |
||
4 | * |
||
5 | * @package WordPress |
||
6 | * @subpackage Strip |
||
7 | */ |
||
8 | |||
9 | get_header(); ?> |
||
10 | <div class="wrap"> |
||
11 | <section id="primary" |
||
12 | <main id="content" role="main"> |
||
13 | |||
14 | <?php if ( have_posts() ) : ?> |
||
15 | |||
16 | <header class="page-header"> |
||
17 | <h1 class="page-title"><?php printf( esc_html__( 'Search Results for: %s', 'strip' ), '<span>' . get_search_query() . '</span>' ); ?></h1> |
||
18 | </header><!-- .page-header --> |
||
19 | |||
20 | <?php /* Start the Loop */ ?> |
||
21 | <?php while ( have_posts() ) : |
||
22 | the_post(); |
||
23 | |||
24 | get_template_part( 'content', get_post_format() ); |
||
25 | |||
26 | endwhile; |
||
27 | |||
28 | the_posts_pagination( array( |
||
0 ignored issues
–
show
Bug
introduced
by
![]() |
|||
29 | 'prev_text' => _x( '←', 'Previous page link', 'strip' ) . '<span class="screen-reader-text">' . __( 'Previous page', 'strip' ) . '</span>', |
||
30 | 'next_text' => '<span class="screen-reader-text">' . __( 'Next page', 'strip' ) . '</span>' . _x( '→', 'Next post link', 'strip' ), |
||
31 | 'before_page_number' => '<span class="meta-nav screen-reader-text">' . __( 'Page', 'strip' ) . ' </span>', |
||
32 | ) ); |
||
33 | |||
34 | else : ?> |
||
35 | |||
36 | <article id="post-0" class="no-results"> |
||
37 | <header class="page-header"> |
||
38 | <h1 class="page-title"><?php esc_html_e( 'Nothing Found', 'strip' ); ?></h1> |
||
39 | </header><!-- .page-header --> |
||
40 | <div class="entry-content"> |
||
41 | <p> <?php esc_html_e( 'Bummer, I cannot find what you are looking for. |
||
42 | Would you like to search in the', 'strip' ); ?> |
||
43 | |||
44 | <a href="<?php echo esc_url( get_post_type_archive_link( 'comic' ) ); ?>">Comics Archive</a>? Great stuff there.</p> |
||
45 | |||
46 | <p><?php esc_html_e( 'Or do you prefer trying another search with different keywords?', 'strip' ); ?></p> |
||
47 | |||
48 | <?php get_search_form(); ?> |
||
49 | |||
50 | <?php endif; ?> |
||
51 | </div><!-- .entry-content --> |
||
52 | </main><!-- #content --> |
||
53 | </section><!-- #primary --> |
||
54 | </div><!-- .wrap --> |
||
55 | |||
56 | <?php get_footer(); ?> |
||
57 |