• I’ve recently updated my permalinks to use the postname but I’ve just found that if I search on my site when I click for older posts I just get a blank page. No ideas why so wondering if anyone else might be able to point me in the direction of a fix?

    You can view a search here http://www.welcomebrand.co.uk/?s=web and if you click on “older posts” it’s just an empty page. (Normal blog article pagination works fine)

    My search.php code is:

    <?php get_header(); ?>
    
    	<?php if ( have_posts() ) : ?>
                <?php get_template_part( 'loop', 'search' ); ?>
                <?php else : ?>
                <article class="primary-content">
                    <h1>Search results: <span><?php _e( 'Nothing Found' ); ?></span></h1>
                    <figure class="alignleft">
                    	<img src="<?php echo bloginfo('template_directory'); ?>/assets/images/nothing-found.jpg" alt="Sorry, nothing quite matches your search" />
                    </figure>
                    <p>I'm very sorry but I couldn't find anything to match your search for "<mark><?php printf( __( '%s' ), '<span>' . get_search_query() . '</span>' ); ?></mark>".</p>
                    <p>If it's something specific you're looking for, please feel free to keep bashing out the keywords but if you still can't find it - <a href="mailto:james@welcomebrand.co.uk">send me an email</a> or if it's design related, perhaps it's something I could write about so don't be afraid to suggest topics!</p>
                </article>
                <?php endif; ?>
    <?php get_footer(); ?>

    If that’s of any help?

    Any ideas on a fix appreciated.

Viewing 1 replies (of 1 total)
Viewing 1 replies (of 1 total)
  • The topic ‘Search pagination not working’ is closed to new replies.