How can I make it so that, until a specific category is selected in the top filter, the product cards from that category are not displayed in the list of product cards below?
Please navigate to HivePress > Settings > Listings > and enable the Display categories instead of listings feature. Then the user will need to first select a category before searching.
Is there a way to implement what I need directly in the code?
Or could you tell me where the query for fetching posts on the homepage is being formed, specifically the query arguments? I think I could add the logic I need in that place.
Please note that this feature works exactly as you describe, i.e. no listings will be shown until you select a category. Please try to enable it and test the functionality.
Thank you for your response.
1. I need all listings to be displayed on the homepage, except for listings from a specific category.
2. Only when I select this specific category in the filter at the top should listings from this category be displayed, while all other listings should be hidden (this part is already working - point 2).
On the homepage, I display listings using the shortcode [wre_archive_listings].
There is no feature in the Listings block that shows all categories except excluded. There is a choice of which category to show, but we will try to add more options in the next updates. “On the homepage, I display listings using the shortcode [wre_archive_listings]” - if you use this shortcode and it shows listings, then HivePress does not have such a shortcode, and an Internet search for this shortcode showed that it is the WP Real Estate plugin.
P.S. Your request is related to a premium product. Please add the license key to the account settings to access forums for your purchased products and get the Premium Support badge on your profile. If the support for your purchase has expired, please consider renewing it for assistance: Renew Support | HivePress