Search results for variable products

Home Forums Product Support Forums Ajax Search Pro for WordPress Support Search results for variable products

This topic contains 1 reply, has 2 voices, and was last updated by Ernest Marcinko Ernest Marcinko 5 months, 1 week ago.

Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • #46607
    HR1904
    HR1904
    Participant

    I use your search for WooCommerce in a shop.

    For variable products i want to achieve the following:
    1. Show only the parent product if the search result shows more than one variation (for example if the search shows size S, M, L etc. i only want to show the parent product).
    2. Search result shows parent product and only one variation => show only the variation and NOT the parent product.

    Thanks.

    #46610
    Ernest Marcinko
    Ernest Marcinko
    Keymaster

    Hi,

    I’m afraid for this you may need some sort of a custom code. I suggest using the asp_results hook, as it serves mainly for manipulating the results before display.
    The rough outline of the code is, that you loop through the items, gather the variations by products in an array, then check the occurences and remove the unwanted items accordingly.

    I usually suggest a custom code where I can, but this may be a bit more complicated than that.

    Best,
    Ernest Marcinko

    If you like my products, don't forget to rate them on codecanyon :)


Viewing 2 posts - 1 through 2 (of 2 total)

You must be logged in to reply to this topic.