-
Search Results
-
Hi Trevor,
I have some questions regarding the usage and hope you can help me.
1. A drop down filter with custom ACF field. I have a front-end form created with ACF where one of the fields is Price. I have created a main filter where i use the range field with two values minimum price and maximum price and it works great. Now i am looking to create another small drop down filter with two options: Sort posts by lowest price and Sort posts by highest price. Sorry if it is obvious, but i could not find how can i achieve it using one single ACF field.
2. The reset button does not work when filter is not submitted with AJAX. Is it how it should behave or am i missing something?
3. Last thing, and perhaps it is a feature request. Would it be possible to make echoed filter labels clickable, so that each label resets/clears the corresponding filter input?
I echo the filters labels using this method:
global $searchandfilter; $sf_current_query = $searchandfilter->get(15197)->current_query()->get_array(); if( isset( $sf_current_query['_sfm_watch_year']['active_terms'] ) ) : $get_years = $sf_current_query['_sfm_watch_year']['active_terms']; $show_year = ''; if ( $get_years ) { foreach( $get_years as $value ) { $show_year .= '<span class="fl">' . $value['name'] . '</span>'; } $label_year = 'Years: ' . rtrim( $show_year, ', ' ); } endif;This code show the labels of years checked checkboxes. What i mean is that years label will have a link and the click event will reset the years filter checkbox.
Thank you!
This strikes me as an easy fix but i’m just not finding the method –
I’m writing a filter results page title like so:
<h1 class="entry-title"><?php echo $sf_current_query->get_field_string("_sft_rugtype"); ?></h1>with _sft_rugtype (aka, Rug Type:) being the taxonomy we’re filtering by, this all works fine but the title gets printed as “Rug Type: [term name]” – we’re looking to exclude the taxonomy in the display so it only says the term name. My apologies if this is documented somewhere i’m struggling to find it.