Looking for support? You can access the support system via your account.
Forums › Forums › Search & Filter Pro › Problem with Woocommerce page filter behaviour
- This topic has 21 replies, 2 voices, and was last updated 3 years, 11 months ago by Trevor.
-
Trevor Moderator(Private) April 2, 2020 at 5:27 pm #238818
Instead of placing the shortcode on the page, what if you enable the sidebar on the shop page:
https://www.screencast.com/t/bR4S35MtxN
and then edit the sidebar here, remove the category widget and our form widget:
https://www.screencast.com/t/e2bPwetZvqH
and
https://www.screencast.com/t/YfkmnDnBS9and then enable the sidebar on the archive page also:
Trevor Moderator(Private) April 3, 2020 at 3:30 pm #238956The title is most likely output by PHP in the theme template that is OUTSIDE the ajax container (it is outside the page content area, in the subheader), and thus that would not get refreshed.
We DO have a script that you could launch an Ajax trigger to refresh the title background, maybe, but the code you need would be very complex I think, and would require the services of a third party coder.
You might ask the author of the theme if they could give you the jQuery to refresh that subheader using Ajax, then it could go inside this script:
<script>(function ( $ ) { "use strict"; $(document).on("sf:ajaxfinish", ".searchandfilter", function(){ // call your ajax script here }); }(jQuery));</script>
Trevor Moderator(Private) April 4, 2020 at 1:27 pm #239057Our plugin can only reload what is inside that container, yes. But, in general, it is possible to trigger a reload of most parts of a page, as long as you do it right. You would need to trigger a reload of the subheader.
Thomas(Private) April 20, 2020 at 4:53 pm #240685Hi Trevor,
Finally managed to make this work.
I have one more question: Do you see any easy way to make the S&F filters contextual? What I mean is, if I select one filter, I would like to Ajax-reloaded page to display only those other filters which, when combined with the already-selected one, display a minimum of 1 result.
Thanks,
ThomasTrevor Moderator(Private) April 21, 2020 at 3:11 pm #240780Do you have these settings:
In the General settings tab of the form:
Set
Auto Count
(both settings) toON
And then in the Form UI:
In each field set
Hide Empty
toON
If not, please try that.
-
AuthorPosts
The topic ‘Problem with Woocommerce page filter behaviour’ is closed to new replies.