Zen Cart Logo
If this is your first visit, check our documentation. To post, register or login.
Forums / Community Contributed Add-Ons / Addon Shipping Modules / Can I Force expedited shipping for a few products in my cart?

Can I Force expedited shipping for a few products in my cart?

Locked
This thread is locked. New replies are disabled.
7 Nov 2008, 9:05 PM
#1
danwebman avatar

danwebman

New Zenner

Join Date:
Nov 2008
Posts:
71
Plugin Contributions:
0

Post #1 by danwebman

I am using the fedex module for 1.3.7. I need to have My chocolates to be shipped overnight or 2day only. I also sell coffee, so I was wondering if there is anything I can input that will identify to my shipping module that everything in my chocolate category will only have the option to be 2Day or Overnight? Thanks!

p.s.- would I be able to have both products in one order and allow different shipping times/types?

9 Nov 2008, 6:05 PM
#2
ajeh avatar

ajeh

Oba-san

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

Post #2 by ajeh

You need something that can identify these products such as:
master_categories_id
products_model
your_unique_field

that can be tested for when products are in the cart ...

Also, you need to determine what happens when you have a mixed cart of chocolates and pecans ... do chocolates rule?

Personally, I think chocolates rule ... :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!

10 Nov 2008, 3:57 AM
#3
danwebman avatar

danwebman

New Zenner

Join Date:
Nov 2008
Posts:
71
Plugin Contributions:
0

Post #3 by danwebman

Cool, I am not sure where I can find the master_categories_id? Also, for now, I think that it would be easiest to just have chocolates rule, if they are in the cart... then there will be only options for expidited shipping (fedexexpress). Since I am using the FedEx module... here is some of the .php code for the "fedexground" that I would like to hide if chocolate is in the cart... :

class fedexground {
var $code, $title, $description, $sort_order, $icon, $tax_class, $enabled, $meter, $intl;
// class constructor
function fedexground()
{
global $order, $db, $template;

			$this->code = 'fedexground';

			$this->title = MODULE_SHIPPING_FEDEX_GROUND_TEXT_TITLE;

			$this->description = MODULE_SHIPPING_FEDEX_GROUND_TEXT_DESCRIPTION;

			$this->sort_order = MODULE_SHIPPING_FEDEX_GROUND_SORT_ORDER;

			if ($order->delivery['company'] == '') {
					$this->icon = DIR_WS_IMAGES . 'fedex-images/HOME.gif';
			} else {
					$this->icon = DIR_WS_IMAGES . 'fedex-images/GROUND.gif';
			} 
			$this->tax_class = MODULE_SHIPPING_FEDEX_GROUND_TAX_CLASS;

			$this->enabled = ((MODULE_SHIPPING_FEDEX_GROUND_STATUS == 'True') ? true : false);

			$this->meter = MODULE_SHIPPING_FEDEX_GROUND_METER;

--AND HERE IS SOME OF THE :

// class methods
function quote($method = '')
{
global $shipping_weight, $shipping_num_boxes, $cart, $order;

			if (zen_not_null($method)) {
					$this->_setService($method);
			} 

Not sure exactly where I should drop the function to test if for the master_categories_id.. I am new to .php, but it seems like it would go underneath this last piece of code I showed you, and would I only put it in this fedexground.php file and not the fedexexpress.php file? Thanks! Your help is amazing!!

13 Nov 2008, 2:02 AM
#4
danwebman avatar

danwebman

New Zenner

Join Date:
Nov 2008
Posts:
71
Plugin Contributions:
0

Post #4 by danwebman

So I have tried every variation from the following module:

http://www.zen-cart.com/forum/showthread.php?t=56242

I cannot get anything to work for me as far as excluding 'FedEx Ground' from my shipping options when chocolates are in the cart... can someone please help me figure out what I am doing wrong. I have been working on this for a week and can't figure it out on my own. Here is my site:
https://www.paynemasonexclusive.com/Catalog

I'm only using the fedex shipping options, not sure where I should be putting the global $cart function, or what the code should be. I only want to exclude the FedEx Ground option if there is chocolate in the cart... here is the fedexground.php if needed?:

http://www.paynemasonexclusive.com/fedexground.rtf

13 Nov 2008, 4:46 AM
#5
ajeh avatar

ajeh

Oba-san

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

Post #5 by ajeh

This can be done ...

However, I would need the full FedEx shipping module files and an account number to work with for this ...

danwebman, if you need someone to write this for you, you may contact me via PM ...

NOTE: no I did not say everyone ... I said danwebman ... thanks ... :smile:

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!