Top

Hide the 1+ Variant (from Quantity Breaks) in the Upsell Window

If you would like to hide the 1+ variant from Quantity Breaks in the upsell window, following these steps:

  1. From "Shopify Admin", select Apps.
  2. Select Product Upsell.
  3. Select Settings.

    Select Settings 

  4. Select Upsell Settings.

    Select Upsell Settings 

  5. Scroll down to the "Custom Design" section.

    Scroll down to custom design 

  6. Enter this JavaScript into the Custom HTML/CSS text box:
    <script>
    jQuery(window).bind("load", function () {
    $( "#upsell_upsell_form #var_id" ).each(function( index ) {
    $QB_var = $(this).text().trim();
    console.log($QB_var, typeof($QB_var), $QB_var.slice(0,1), $QB_var.length);
    if ($QB_var.slice(0, 1) == "1" && $QB_var.length <= 4 ) {
    $(this).remove();
    }
    });
    });
    </script>

    add the javascript 

  7. Select Save.

    select save 

That's it!

Have more questions? Submit a request