This code creates a custom WooCommerce product query using WC_Product_Query enabling you to use any WP_Query parameters.
Works with WC Product Query parameters in WooCommerce.
There’s only 1 step :
Copy & paste the PHP code ( excluding the opening PHP tag ) from the functions.php file to the end of your child themes functions file or custom functionality plugin.
You may also like…
These solutions may also help :