Display three best products

0.0/5
<?php
add_action( 'elementor/query/three_best_selling', function( $query ) {
	$query->set( 'post_type', 'product' );
	$query->set( 'meta_key', 'total_sales' );
	$query->set( 'orderby', 'meta_value_num');
	$query->set( 'posts_per_page', 3);
} );

Comments and reviews

{{ reviewsTotal }} Review
{{ reviewsTotal }} Reviews
{{ options.labels.newReviewButton }}
{{ userData.canReview.message }}

Description

This snippet was fetched automatically from WPDistro.cz projects.

Author

Tags

This snippet is untagged