Forums › Forums › Search & Filter Pro › Using short-code on term pages to pull only current term results.
Tagged: shortcode, term archives
- This topic has 4 replies, 3 voices, and was last updated 4 years, 8 months ago by Ross.
-
Anonymous(Private) April 16, 2020 at 9:49 pm #240357
Hey Trevor, I need to figure out a way to use one filter (with two options) as a shortcode on term pages. I am using the beaver builder.
I have 6 terms attached to a post type (member);
What I am looking for is to use the same filters (set post type and all other settings will be the same) and have the results be restricted to the term the visitor is on. I know I can duplicate the filter 6 times, but I would like to see if there is already a shortcode setting I can use. Thanks.On term archive page using if-else or passing the current term slug:
[searchandfilter id=”2550″]
[searchandfilter id=”2550″ fields=”current-term-name” show=”results”]
Trevor(Private) April 17, 2020 at 9:49 am #240380If you are using Beaver Builder, maybe this will be of interest (but, it might not):
https://searchandfilter.com/documentation/3rd-party/beaver-builder/
The results shortcode you show is not valid, and cannot be.
When using the shortcode display method, its use is restricted to one results page. You can have the form on many pages though, but the form submission will redirect to that single results page.
If you are placing the form on taxonomy term archive pages, you can auto detect the term of that page by making sure that the taxonomy itself is in the form (if you do not want the user to see it, use custom CSS to hide it) and to select, on the General settings tab of the form, the Auto Detect option for Tags, Categories and Taxonomies.
Anonymous(Private) April 17, 2020 at 9:25 pm #240501Hey, the addon is great. one issue with it though; I have other post type archive pages which I use shortcode and custom result template from theme folder and once I enabled the addon the archive page couldnt find error popped up. So I think we cant mix how we use it?
-
AuthorPosts