Forums / Built-in Shipping and Payment Modules / Flat rate shipping with a minimum purchase

Flat rate shipping with a minimum purchase

Views: 1,380

Results 1 to 7 of 7
12 Apr 2011, 5:09 AM
#1
johnny_roastbeef avatar

johnny_roastbeef

New Zenner

Join Date:
Dec 2010
Posts:
56
Plugin Contributions:
0

Flat rate shipping with a minimum purchase

I would like to do flat rate shipping on all orders above a minimum purchase of $75. Orders below that threshold would pay standard UPS or USPS rates. Is there a way to do this?
-thanks

12 Apr 2011, 2:06 PM
#2
ajeh avatar

ajeh

Oba-san

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

Re: Flat rate shipping with a minimum purchase

You can control this by customizing the shipping modules ...

To not show the Flat Rate flat shipping module you can add the code in red:

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

      // bof: do not show if <= $75.00
      if ($order->info['total'] <= 75) {
        $this->enabled = false;
      }
      // eof: do not show if <= $75.00

Then, to allow UPS or USPS reverse the logic and place the code in red in approximately the same location so that the shipping does not show on orders > $75.00 ...

      $this->enabled = ((MODULE_SHIPPING_USPS_STATUS == 'True') ? true : false);
      // bof: do not show if > $75.00
      if ($order->info['total'] > 75) {
        $this->enabled = false;
      }
      // eof: do not show if > $75.00

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!

12 Apr 2011, 3:33 PM
#3
johnny_roastbeef avatar

johnny_roastbeef

New Zenner

Join Date:
Dec 2010
Posts:
56
Plugin Contributions:
0

Re: Flat rate shipping with a minimum purchase

Ajeh,
Which php file would need to be modified?
Thank you for your help
-john

12 Apr 2011, 3:53 PM
#4
ajeh avatar

ajeh

Oba-san

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

Re: Flat rate shipping with a minimum purchase

Your shipping modules code files are located in:
/includes/modules/shipping

Flat Rate is flat.php
USPS is usps.php
UPS is ups.php

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!

12 Apr 2011, 7:59 PM
#5
johnny_roastbeef avatar

johnny_roastbeef

New Zenner

Join Date:
Dec 2010
Posts:
56
Plugin Contributions:
0

Re: Flat rate shipping with a minimum purchase

Ajeh,
As if you didnt already know. This worked perfectly. :D
thank you very much!!!
-john

12 Apr 2011, 8:00 PM
#6
ajeh avatar

ajeh

Oba-san

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

Re: Flat rate shipping with a minimum purchase

Thanks for the update and glad that this is now working for you ... :cool:

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!

9 Aug 2011, 5:03 PM
#7
johnny_roastbeef avatar

johnny_roastbeef

New Zenner

Join Date:
Dec 2010
Posts:
56
Plugin Contributions:
0

Re: Flat rate shipping with a minimum purchase

OK, this is working perfectly. But now I have a new issue. We would like to add some items to the store that are very heavy, but fairly inexpensive. I would like to have these new products omitted from the flat rate shipping mod that we have done. Or in other words, I would like to charge actual shipping costs for just some specific items.

I know I can add a flat shipping fee onto these items, which we already do for for expensive products that are also expensive to ship. Unfortunately, due to the price of these items, charging a nearby customer the same shipping fee as someone across the country will just cost sales. Is there a way to just omit certain items from this mod?

thanks
-john