Custom Search Result page

Hello !

I made a search result page with the layout builder.
Everything works fine except that I would like to display only products with a defined category and not display “unclassified” products.

Here in the example, only the " ensemble " products must be displayed in the results because they are defined in a “category” (here “bikini”) but the other products have no category and they must not appear.

They should not appear because the " ensemble " are actually a bundle of two products that are not sold individually but only as a set.

How to proceed ?

Thanks !

Hi Michael,

Thanks for reaching out.
It seems that you are trying to remove the Products which does not have any category from the Search Result page. If that is the case, you need to remove the Uncategorized product from the search result.



Hope it helps.
Thanks

Hello,

It works but partially!

The unwanted results have disappeared as expected but I have a display bug.
I think it’s related to the looper provider but I can’t figure out why?!

Do you have an idea?

It happens on every search

Hi Michael,

The issues you are currently having might be some other reason. I would request you remove the code added to remove the uncategorized and check if this issue is resolved. If you still find the issue without the code, I would request you please provide login credentials for your site in a secure note to examine it further, including:

– WordPress Site URL & Login URL
– WordPress Admin username/password
– Specific layout for Search Result

To create a secure note, click the key icon underneath any of your posts.

Thanks

Hi Michael,

I have checked your layout thoroughly and found that it shows the result from pages too. I went ahead and set the condition for Post Type is Product and the Featured Image is set and now it is showing the proper output.

Thanks

Hi Tristup,

Génial ! Merci ! :pray:

Hi Michael,

You are most welcome.

This topic was automatically closed 10 days after the last reply. New replies are no longer allowed.