WooCommerce - excelling eCommerce
Variable Product Prices (6 posts)

  1. cdminc
    Posted 2 years ago #

    Currently WooCommerce show the lowest price for a variable product. Is there a way to adjust this so that another price appears. Let me explain…

    In the mattress industry it is standard to list the price of a queen size mattress. The lowest price is obviously the twin size. I would like to display the queen price first in my variable product. Thank you in advance for your help.


  2. bheadrick
    Posted 2 years ago #

    sure, you could just use the woocommerce_variable_price_html filter hook

    Would you still want it to say from $___ or some other verbiage?

  3. cdminc
    Posted 2 years ago #

    Hi bheadrick,
    Thank you for your help. I'd like to change "from" to "queen".

  4. cdminc
    Posted 2 years ago #

    This link might be helpful to others

  5. cdminc
    Posted 2 years ago #

    Here is another link closer to what I am looking for. Now I just need to figure out how to select the "queen" size price variable. Any ideas?


  6. cdminc
    Posted 2 years ago #

    If my product variation are Twin,Queen,King how would I display the "QUEEN" size using the code below:

    add_filter('woocommerce_variable_price_html', 'custom_price_text', 10, 2);

    function custom_price_text( $price, $product ) {

    $price = '';
    $price .= '<span class="from">' . _x('A4 Sample', 'min_price', 'woocommerce') . ' </span>';
    $price .= woocommerce_price($product->get_price());

    return $price;

Topic Closed

This topic has been closed to new replies.

About this Plugin

  • WooCommerce - excelling eCommerce
  • Frequently Asked Questions
  • Support Threads
  • Reviews

About this Topic