Forums / Built-in Shipping and Payment Modules / Make entire order free shipping if one item is free shipping

Make entire order free shipping if one item is free shipping

Started by sfischer on 21 Jan 2010, 5:01 AM · Views: 2,819

Results 1 to 7 of 7
21 Jan 2010, 5:01 AM
#1
sfischer avatar

sfischer

New Zenner

Join Date:
May 2008
Location:
Louisiana
Posts:
18
Plugin Contributions:
0

Make entire order free shipping if one item is free shipping

I apologize if this has been asked before but I couldn't find it anywhere.

I have some items free shipping and some not. Is there some way to tell ZC that if one item is free shipping, the whole order is free shipping?

For example, I might have a $150 item that I offer free shipping. If a customer adds a $10 widget to the order, they're charged shipping on the widget. I'd like to make that whole order free shipping and I can't do it with the order total option because I also have some $150 items that aren't free shipping.:unsure:

21 Jan 2010, 5:09 AM
#2
ajeh avatar

ajeh

Oba-san

Join Date:
Sep 2003
Location:
Ohio
Posts:
62,757
Plugin Contributions:
1

Re: Make entire order free shipping if one item is free shipping

What shipping modules do you have installed at this time?

Linda McGrath
If you have to think ... you haven't been zenned ...

**Did YOU buy the Zen Cart Team a cup of coffee and a donut today? Just click here to support the Zen Cart Team!!**

Are you using the latest? Perhaps you've a problem that's fixed in the latest version: [Upgrade today!]
Officially PayPal-Certified! Just click here

Try our Zen Cart Recommended Services - Hosting, Payment and more ...
Signup for our Announcements Forums to stay up to date on important changes and updates!

21 Jan 2010, 5:12 AM
#3
ayurfoods avatar

ayurfoods

New Zenner

Join Date:
Mar 2008
Location:
Foster City (Silicon Valley), CA, USA
Posts:
10
Plugin Contributions:
0

Re: Make entire order free shipping if one item is free shipping

I have exactly the same problem. Our shipping costs are based on product weight. When the customer has a mixed order of free-shipping and not-free-shipping products, estimator takes the weight of all products (free and not-free) while calculating rates. Any suggestions to make the entire order free-shipping including the estimator will be helpful.

We have UPS and USPS shipping modules installed.

Atul Apte
https://www.ayurfoods.com
A happy Zen Cart user

21 Jan 2010, 5:22 AM
#4
sfischer avatar

sfischer

New Zenner

Join Date:
May 2008
Location:
Louisiana
Posts:
18
Plugin Contributions:
0

Re: Make entire order free shipping if one item is free shipping

Thanks Linda. You always come to my rescue.

I currently have:
Flat Rate
Free Shipping Options
FREE SHIPPING!
United Parcel Service upsxml

21 Jan 2010, 2:57 PM
#5
ajeh avatar

ajeh

Oba-san

Join Date:
Sep 2003
Location:
Ohio
Posts:
62,757
Plugin Contributions:
1

Re: Make entire order free shipping if one item is free shipping

This is a long version of how to test the qty for Always Free Shipping that is in the cart to disable the flat.php shipping module:

      // disable only when entire cart is free shipping
      if (zen_get_shipping_enabled($this->code)) {
          $this->enabled = ((MODULE_SHIPPING_FLAT_STATUS == 'True') ? true : false);
      }

      // test contents for Cases
       global $cart;
        $skip_free = false;
        $chk_case = 0;

        if (IS_ADMIN_FLAG == false) {
          $chk_case = $_SESSION['cart']->in_cart_check('product_is_always_free_shipping', 1);
          if ($chk_case > 0) {
            $skip_free = true;
          }
        }
//echo 'Qty Always Free Shipping: ' . $chk_case . '<br>';
      // disable for 1 or more Always Free Shipping in cart
      if ((IS_ADMIN_FLAG == false && $skip_free)) {
          $this->enabled = false;
      }

You can use this to enable or disable modules based on the results ...

Linda McGrath
If you have to think ... you haven't been zenned ...

**Did YOU buy the Zen Cart Team a cup of coffee and a donut today? Just click here to support the Zen Cart Team!!**

Are you using the latest? Perhaps you've a problem that's fixed in the latest version: [Upgrade today!]
Officially PayPal-Certified! Just click here

Try our Zen Cart Recommended Services - Hosting, Payment and more ...
Signup for our Announcements Forums to stay up to date on important changes and updates!

24 Jun 2010, 1:48 AM
#6
purelife avatar

purelife

New Zenner

Join Date:
May 2010
Posts:
8
Plugin Contributions:
0

Re: Make entire order free shipping if one item is free shipping

does the newest zen cart version have this feature? Or anybody else tested the above script does it work well?

Thanks. :smile:

3 Oct 2011, 1:14 PM
#7
zskiman avatar

zskiman

New Zenner

Join Date:
Mar 2005
Posts:
69
Plugin Contributions:
0

Re: Make entire order free shipping if one item is free shipping

i am having issues getting this to work, if i add something to the cart that has free shipping its fine , free shipping displays but if i add another item that does'nt have free shipping i get

Not Available At This Time
Sorry, We are not able to ship outside the US at this time.
Please contact us for alternate arrangements.

i am adding the snippet to table,table2 and table3 modules.

using zen-cart 1.3.9h, also using fec with ajax

any help would be appreciated.

thanx

Never be afraid to try something new, remember that amateurs built the ark, professionals built the Titanic