-
Notifications
You must be signed in to change notification settings - Fork 0
/
search.php
56 lines (40 loc) · 1.65 KB
/
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
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
<?php
/**
* @package WordPress
* @subpackage Yoko
*/
get_header(); ?>
<div id="wrap">
<div id="main">
<div id="content">
<?php if ( have_posts() ) : ?>
<header class="page-header">
<h1 class="page-title">Ricerca per “<?php echo get_search_query(); ?>” <span class="dets">(<?php echo $wp_query->found_posts; ?> risultati)</span></h1>
</header><!--end page-header-->
<?php /* Start the Loop */ ?>
<?php while ( have_posts() ) : the_post(); ?>
<?php get_template_part( 'content', 'search' ); ?>
<?php endwhile; ?>
<?php /* Display navigation to next/previous pages when applicable */ ?>
<?php if ( $wp_query->max_num_pages > 1 ) : ?>
<nav id="nav-below">
<div class="nav-previous"><?php next_posts_link( __( '<span class="meta-nav">←</span> Older posts', 'yoko' ) ); ?></div>
<div class="nav-next"><?php previous_posts_link( __( 'Newer posts <span class="meta-nav">→</span>', 'yoko' ) ); ?></div>
</nav><!-- end nav-below -->
<?php endif; ?>
<?php else : ?>
<article id="post-0" class="post no-results not-found">
<header class="page-header">
<h1 class="page-title"><?php _e( 'Nothing Found', 'yoko' ); ?></h1>
</header>
<div class="single-entry-content">
<p>Spiacenti, nessun risultato per il criterio di ricerca.</p>
<p>Prova con una nuova chiave di ricerca:</p>
<?php get_search_form(); ?>
<img class="notfound" src="<?php echo get_stylesheet_directory_uri() ?>/images/404_teddy_bear_toy.png" />
</div>
</article>
<?php endif; ?>
</div><!-- end content -->
<?php get_sidebar(); ?>
<?php get_footer(); ?>