This website uses cookies to personalize your experience. By using this website you agree to our cookie policy.

Reply To: Override default WP search result does NOT work when using an Elementor template

Home Forums Product Support Forums Ajax Search Pro for WordPress Support Override default WP search result does NOT work when using an Elementor template Reply To: Override default WP search result does NOT work when using an Elementor template

#25272
Ernest MarcinkoErnest Marcinko
Keymaster

Hi,

Recently a similar issue was reported, it only occured once so far. There was a problem with the detection of the query, and I had to directly modify one of the files.

For now, you should be able to resolve it via a small custom code snippet, until the next release is out. Try adding this custom code to the functions.php in your theme/child theme directory. Before editing, please make sure to have a full site back-up just in case!

add_filter('asp_query_is_search', 'asp_query_is_search_override', 10, 2);
function asp_query_is_search_override( $is_search, $wp_query ) {
	return method_exists($wp_query, 'is_search') && $wp_query->is_search();
}