Viewing 9 posts - 1 through 9 (of 9 total)
  • Author
  • #225840

    Hi there,
    the adjustments for the new woocommerce update seem to mostly work just fine. thanks for that!
    one thing that bothers me is that in the prior version while using a variable product the shop page displays the pricing as ‘from x Euro’. now this was changes to: ‘From x Euro to x Euro’… i am not sure if this makes more sense to me, maybe it helps it searches, tags or similar.

    i wonder how i can change back to the prior display (from x Euro)?
    the other reaso i dont like the new pricing display is that the formatting comes pretty unusual – the spaces between characters and numbers are a bit weird. If i could change that too, that would be great.

    here is what i meant:

    thanks in advance for your hard work!
    my best regards


    Thanks. would thaat be functions.php or functions-enfold.php when they ask to insert it into the themes functions.php?
    any specific place in the php to add it?

    thanks in advance



    I recommend to add it at the very bottom of functions.php.




    You can this at the very bottom of functions.php:

    // Use WC 2.0 variable price format
    add_filter( 'woocommerce_variable_sale_price_html', 'wc_wc20_variation_price_format', 10, 2 );
    add_filter( 'woocommerce_variable_price_html', 'wc_wc20_variation_price_format', 10, 2 );
    function wc_wc20_variation_price_format( $price, $product ) {
    	$min_price = $product->get_variation_price( 'min', true );
    	$price = sprintf( __( 'From: %1$s', 'woocommerce' ), wc_price( $min_price ) );
    	return $price;

    Best regards,


    Thanks Ismael for the quick response.
    If i put the code exactly how it is at the bottom of the theme’s function.php it somehow freezes the site.
    any idea what it could be?



    Do you have access to your PHP log? can you post the last reports?


    This reply has been marked as private.

    Hey Ismael,

    Just wanted to say your // Use WC 2.0 variable price format // snippet works perfect.
    Thanks 4 the support.


Viewing 9 posts - 1 through 9 (of 9 total)

The topic ‘price range for variable products on woocommerce shop page’ is closed to new replies.