blogside/search.php

51 lines
1.3 KiB
PHP
Raw Permalink Normal View History

2016-02-03 11:28:05 +01:00
<?php get_header(); ?>
2017-03-05 21:42:58 +01:00
<div class="content">
2016-02-03 11:28:05 +01:00
<?php get_template_part('inc/page-title'); ?>
<div class="pad pad-top group">
<div class="notebox">
2018-10-31 13:03:44 +01:00
<?php esc_html_e('For the term','blogside'); ?> "<span><?php echo get_search_query(); ?></span>".
2016-02-03 11:28:05 +01:00
<?php if ( !have_posts() ): ?>
2018-10-31 13:03:44 +01:00
<?php esc_html_e('Please try another search:','blogside'); ?>
2016-02-03 11:28:05 +01:00
<?php endif; ?>
<div class="search-again">
<?php get_search_form(); ?>
</div>
</div>
</div><!--/.pad-->
<?php if ( have_posts() ) : ?>
2017-12-16 20:58:17 +01:00
<?php if ( get_theme_mod('blog-layout') == 'blog-grid' ) : ?>
2016-02-03 11:28:05 +01:00
<div class="post-grid group">
<?php $i = 1; echo '<div class="post-row">'; while ( have_posts() ): the_post(); ?>
<?php get_template_part('content-grid'); ?>
<?php if($i % 2 == 0) { echo '</div><div class="post-row">'; } $i++; endwhile; echo '</div>'; ?>
</div><!--/.post-list-->
2017-12-16 20:58:17 +01:00
<?php elseif ( get_theme_mod('blog-layout') == 'blog-list' ) : ?>
2016-02-03 11:28:05 +01:00
<?php while ( have_posts() ): the_post(); ?>
<?php get_template_part('content-list'); ?>
<?php endwhile; ?>
<?php else: ?>
<?php while ( have_posts() ): the_post(); ?>
<?php get_template_part('content'); ?>
<?php endwhile; ?>
<?php endif; ?>
<?php get_template_part('inc/pagination'); ?>
<?php endif; ?>
2017-03-05 21:42:58 +01:00
</div><!--/.content-->
2016-02-03 11:28:05 +01:00
<?php get_sidebar(); ?>
<?php get_footer(); ?>