Forums Forums Search & Filter Pro How to exclude some categories from widget result ?

Viewing 10 posts - 1 through 10 (of 14 total)
  • Anonymous
    #236256

    Hello,

    I’ve a post widget that show woocommerce product and that, to can work, need to have before this script inserted in a text widget :

    [searchandfilter id=”5236″ action=”filter_next_query”]
    <script>(function ( $ ) {
    “use strict”;
    $(document).on(“sf:ajaxfinish”, “.searchandfilter”, function(){
    elementorFrontend.hooks.doAction(‘frontend/element_ready/posts.cards’,
    jQuery(‘.elementor-widget-posts’));
    });
    }(jQuery));</script>

    now in the post widget under this script i’ve all the products but i need that on this wodget mus be shown only the categories taht i’ce set on the search form and not all.

    in the widget post , related to wuery section. has set the posrt source so i can not select the correct categories to be sxcluded.
    How can i reach this reasult?

    Thank You

    Anonymous
    #236258

    Categories id that i’d want to exclude are the same that i’ve excluded on the search form and are : 15,42,108,107,142,19,22,103,21,104,105,109,110

    Trevor
    #236263

    In the form, did you try to exclude those IDs on the Tags, Categories and Taxonomies settings tab?

    Anonymous
    #236284

    Hello Trevor,
    The tabs refering to post and not to produtc so when i try to search them on the elementor widget post they are not present because isee only the post categorie and not the product categories.
    On the search form it is correct but i need that in the widget post under the search form i do ont see all products but only that included on the search.
    Thank You

    Anonymous
    #236286

    The form work perfectly but it is the widget post under the form on that i can no t manage the product categories being that the widget is realted to post and not to product.
    Do you remembre that we have used the post widgt with taht code in a widget text to can be used to receive the query result ?

    Trevor
    #236404
    This reply has been marked as private.
    Anonymous
    #236457
    This reply has been marked as private.
    Anonymous
    #236467

    You’ll found two search forms but the second is only a “TEST” for an other thing taht i’m trying to solve.
    Thank You

    Trevor
    #236522
    This reply has been marked as private.
    Anonymous
    #236523

    Very Nice,
    I’ve used in the first time but after i’ve removed all and nwo i’ve better understood what is that section.
    There is a little problem about the exclusion because if i exclude teh category it exclude also all the other categories that hai inside the specific category and form me this is not ok.

    F.E. if i exclude PIZZE TONDE i only want that the speicfic singel categry must not be shown and not the products with PIZZE TONDE and MOZZARELLA and POMODORO and etc etc

    I’ve been fairly clear in my explain ?

    I’d need only that in widget post under the search form i do not see the CATEGORY and not all product related to categry AND other category

Viewing 10 posts - 1 through 10 (of 14 total)