Hey guys can anyone help me understand how the predictive search works in Enfold ? It is racking my brain.
Search for ipad 2 repairs, look at the results
I have an actual product called ipad 2 repairs and when you press search that result is top, why is that not showing on the dropdown ?
Hey gloopy1!
The AJAX search returns 5 posts and it sorts them based on type so there most likely is just not enough space to view the item there. If you click on “View all results” you can see the item.
Cheers!
Elliott
Elliot i understand that to an extent but searching for the EXACT text should bring that result to the top ?
Hi!
Try to add this on functions.php:
add_filter('avf_ajax_search_query', 'avf_modify_ajax_search_query', 10, 1);
function avf_modify_ajax_search_query($search_parameters)
{
$order = 'orderby=title&order=DESC&';
$search_parameters = $order . $search_parameters;
return $search_parameters;
}
You can replace the orderby and order parameter.
Best regards,
Ismael
Hi Ismael that makes it worse, it shows an irrelavant product as you can see here
Hey!
I’ve been watching this thread and waiting for the result. Sorry if it doesn’t work. Please remove the code and try to use the Relevanssi plugin then refer to this link: http://kriesi.at/documentation/enfold/use-relevanssi-in-search-instead-of-the-default-search/
Regards,
Ismael
Hi Ismael, i know i can do that but thought that’s an easy approach. I will look more into it