Forums › Forums › Search & Filter Pro › Customize design/appearence of both search form and results
Tagged: related products, V3
- This topic has 15 replies, 2 voices, and was last updated 4 years, 1 month ago by Trevor.
-
Anonymous(Private) March 14, 2020 at 8:29 pm #236708
Hi Trevor,
I want to use searchandfilter to create a “related products” post list. For that I need to set the filter dynamicaly in other words it should detect the taxonomy of the current product and then provide other products with the same taxonomy.
In searchandfilter I found the option: “When a Search Form is used on any page other than the Search Results Page, S&F will try to detect the post type and associated taxonomies of the current page – and set defaults in the Search Form to match these.”
But how does that work practically? Is it even possible what I want? Btw, I think I know how to hide the filter and only show the results.
Regards
DavidTrevor(Private) March 16, 2020 at 3:27 pm #236811The filter cannot, from a single post page, detect what that posts’ taxonomy is and thus create the lists that you want. It is unlikely you could use a form to do this, as, in the main, the form requires a fixed or known results page. This should change in V3 (due in a few months), but I am unsure whether it could even then detect the taxonomy of a post on a single post page.
Trevor(Private) September 18, 2020 at 11:21 am #260014Yes it is. The Search & Filter Pro Text Search field uses the standard WordPress search, so looks only in the Post Title and Content. To help you control this better, on the form’s Advanced settings tab you will see 2 settings for Relevanssi.
The documentation for this is here:
https://www.designsandcode.com/documentation/search-filter-pro/3rd-party/relevanssi/
You would need to install and activate the free Relevanssi plugin as well.
Then set Relevanssi up and build its index (make sure it is indexing the desired post types, custom fields AND any taxonomy that you want to search).
-
AuthorPosts