How to Set Up Product Sorting in WooCommerce
-
Hello,
I’m having an issue with sorting products in WooCommerce. I want to configure the product archive page so that products from category ID 221 are displayed first, followed by all other products.
I’ve tried several methods but none have produced the desired result. Here’s what I’ve attempted:
- Added custom SQL queries to sort products.
- Used filters like
posts_clauses
,posts_orderby
, andpre_get_posts
, but so far all my attempts either result in no products from the desired category being displayed or a mix of products from all categories.
Has anyone faced a similar issue and can provide a working solution? I would appreciate any advice or code examples that could help achieve the desired product order.
Thank you in advance for your help!
The page I need help with: [log in to see the link]
Viewing 4 replies - 1 through 4 (of 4 total)
Viewing 4 replies - 1 through 4 (of 4 total)
- You must be logged in to reply to this topic.