Search Results not working as expected
-
First off, great plugin! It works really well but I am having some weird results when performing a search. I am using relevanassi and Search Autocomplete along with Ajax Load More.
Here’s what’s happening:
When search for the term “long” (http://goodwillsp.wpengine.com/search/long) – The preloaded posts contain the term but when you load more through the ajax button, they seem to just be random and do not contain the search term. Below is the shortcode I am using.<?php if ( have_posts()) : $cat = get_category( get_query_var( 'cat' ) ); $category = $cat->slug; $term = $_GET['term']; $author = get_the_author_meta('ID'); echo do_shortcode('[ajax_load_more post_type="post" preloaded="true" category="'.$category.'" author="'.$author.'" search="'.$term.'" posts_per_page="4" pause="true" transition="fade" button_label="Load More"]'); endif; ?>Additionally, if you search for “WordPress” (http://goodwillsp.wpengine.com/search/wordpress/), the autocomplete shows there are 3 matching results but no posts are preloaded and nothing displays.
Any help is greatly appreciated.
The topic ‘Search Results not working as expected’ is closed to new replies.