Home › Forums › Support › /?s= is returning a null set of results rather than all results This topic has 9 replies, 2 voices, and was last updated 6 years, 4 months ago by Tom. Viewing 10 posts - 1 through 10 (of 10 total) Author Posts December 18, 2017 at 11:01 pm #452643 Phil Hi! How should I modify the default search.php to deliver all results when no search term is specified? Thanks! December 18, 2017 at 11:11 pm #452648 TomLead Developer Lead Developer Hmm I wonder if there’s a way to tell WP to query all posts if the search is empty using a filter like: https://codex.wordpress.org/Plugin_API/Action_Reference/pre_get_posts It may be worth asking over on https://wordpress.stackexchange.com/. Otherwise you would likely need to add the no-results.php file to your child theme, then write the query in there. December 19, 2017 at 6:45 am #452879 Phil Thank you! I noticed that on generatepress.com, a null string pulls in the latest blog posts: https://generatepress.com/?s= Is that what should be happening with the existing search.php template? My /?s= gets a “Nothing found”. If I can get it to pull in the latest posts instead, that would be perfect! December 19, 2017 at 10:12 am #453163 TomLead Developer Lead Developer Ah strange – that should be the default then, as generatepress.com doesn’t do anything special in this area. Perhaps you have a plugin conflicting with the query? December 19, 2017 at 10:17 am #453175 Phil I agree with you! It looks like a problem other than something related to GeneratePress. Thanks for looking into it! December 19, 2017 at 10:27 am #453194 TomLead Developer Lead Developer No problem – you can try deactivating your plugins one by one until it starts working to find the issue ๐ December 19, 2017 at 10:33 am #453203 Phil Thanks! December 19, 2017 at 5:09 pm #453419 TomLead Developer Lead Developer No problem! December 19, 2017 at 5:13 pm #453425 Phil Oh, btw, it was Relevanssi that was hanging things. I’m now working with them to figure out why. Appreciated it! December 19, 2017 at 5:17 pm #453428 TomLead Developer Lead Developer Thanks for letting me know! ๐ Author Posts Viewing 10 posts - 1 through 10 (of 10 total) You must be logged in to reply to this topic. Log In Username: Password: Keep me signed in Log In