Forums › Forums › Search & Filter Pro › Question about archive page and reset button
- This topic has 9 replies, 2 voices, and was last updated 5 years, 11 months ago by
Anonymous.
-
Anonymous(Private) May 10, 2019 at 3:20 pm #210792
Hi there,
First off thanks for the great plugin and excellent support.
I have one main usability issue I can’t quite figure out how to fix. Here’s the situation:
– on homepage (index.php is the results archive page) all search and filter behaviour is as expected.
– on a category archive page the correct category is already selected in the filter (perfect), BUT if I hit the clear all filters button then I am still on a category archive page, say for “text” and now I am seeing filter options for the other categories: video, audio and the results are loaded in the grid.
One solution I can think of is to remove the breadcrumb nav and archive page title so that once a user has reset the filters they don’t actually know that they are on the “text” archive page. That works for the intent because now they are searching all the categories, but it feels a bit weird to conceal where you are. I don’t know if there’s some WordPress or other usability penalty for that down the road.
Another idea is something conditional: if(is_category=”2″) then exclude all !category=”2″ options from the filter.
Or maybe there is another better way that you are already accustomed to suggesting.
Thanks!
Alice
Trevor(Private) May 10, 2019 at 3:53 pm #210805Did you, in the General settings tab:
Set
Auto Count
(both settings) toON
And then in the Form UI:
In each field set
Hide Empty
toON
?Are you using the Post Type Archive display results method and are you using the option to remain the archive pages?
Anonymous(Private) May 10, 2019 at 4:02 pm #210813Auto count both on – yes.
Hide Empty is set to on in all fields
Display results method = “As an archive”
The option to remain on the archive pages, I’m not sure which one that is. I have “Only use Ajax on the result page?” unchecked. If that’s the one I could try checking that and test.
Trevor(Private) May 10, 2019 at 4:50 pm #210835Ok, I made one setting change, one that you couldn’t see. If that hasn’t fixed the category archive page issue, can you give me a sample link to go to that I can see the problem firsthand?
You need to explain this in more detail to me:
Another idea is something conditional: if(is_category=”2″) then exclude all !category=”2″ options from the filter.
Anonymous(Private) May 10, 2019 at 5:27 pm #210841Thanks Trevor. I definitely appreciate your support.
Here’s a screencast of what I mean (taken just now). You see me go to the video category archive page and as expected (perfect) I just see the video option in the filter. Audio and Text are hidden. Then I click the reset button and I’m still on the video archive page (see title) but now I can have the grid show audio items if I check that in the filter.
I guess what I want to happen, so users don’t get confused, is that you never see the other category filter options (audio or text) if you are on the video category page and vice-versa.
So either something conditional that checks if it’s a category archive page and hides all other categories for the filter while it’s still that archive page.
Or I can just do away with the archive page titles and current nav item highlighting. But that feels less good.
Or maybe there’s another better solution.
Thanks,
Alice
Anonymous(Private) May 11, 2019 at 11:44 am #210861I thought of a good solution in the night and will test it today.
I’ll use the widget logic plugin and duplicate the filter so I have a home, video, audio, and text version of the search/filter.
In each version of the duplicate search/filter I will exclude the other main categories from the top category field.
Then I’ll just use the widget logic to find out if it’s the home page – show the home search/filter version, if it’s video archive show that version and so on.
Should work. Will confirm.
Thanks,
Alice
p.s. I won’t bother doing it for all the taxonomies, just those top level category archives. For another version it would be great to have the cat/tax conditional built in so if you are on tax id 5 only show results of 5 and it’s children and exclude the other tax siblings and ancestors.
Anonymous(Private) May 15, 2019 at 3:33 pm #211310It worked. I forgot to get back to you but for anyone else looking for conditional search & filter display it’s easy enough to duplicate your main filter, make whatever edits you want for an archive page etc.. (E.g. for me on the video archive page I wanted to exclude all text and audio categories so I created a video archive filter from a duplicate of my main -all cats- filter.) Then use the widget logic plugin in a sidebar to show the appropriate filter if is_category(’16”) or is_home().
All set now thanks.
Alice
-
AuthorPosts