I am using the following code in child function.php but it is not working:
add_filter(‘woocommerce_related_products_args’, function($args) {
$args[‘orderby’] = ‘title’;
$args[‘order’] = ‘ASC’;
return $args;
}, 9999);
Please help,
Thanks