Need Help with Woocommerce

Jiren

Member
Oct 2, 2018
80
15
8
Hello guys i need help with Woocommerce grouped price.
I want the grouped product to show only the price from the cheapest product.
Im currently using this code, works perfectly but only shows the sale price.
I want to be able to show and the regular price

Code:
add_filter( 'woocommerce_grouped_price_html', 'bbloomer_grouped_price_range_from', 10, 3 );
 
function bbloomer_grouped_price_range_from( $price, $product, $child_prices ) {
$prices = array( min( $child_prices ), max( $child_prices ) );
$price = $prices[0] !== $prices[1] ? sprintf( __( '%1$s', 'woocommerce' ), wc_price( $prices[0] ) ) : wc_price( $prices[0] );
return $price;
}

example:
14348 to be shown like this 14349
 

About us

  • Our community has been around for many years and pride ourselves on offering unbiased, critical discussion among people of all different backgrounds. We are working every day to make sure our community is one of the best.

Quick Navigation

User Menu