- This topic has 13 replies, 2 voices, and was last updated 9 years, 1 month ago by .
Posted
by
Forums › Forums › Search & Filter Pro › user specific results
Hello Trevor,
I’ve tried
function filter_function_name( $query_args, $sfid ) {
$cat_id = array(1);
//if search form ID = 225, the do something with this query
if($sfid==32)
{
$query_args = array(
'category__in' => array($cat_id),
);
}
return $query_args;
}
add_filter( 'sf_edit_query_args', 'filter_function_name', 20, 2 );
Is that right? It returns no results – seems not to extend the query ?
Best
P.