Forums / Addon Shipping Modules / Number of Boxes (UPSXML)

Number of Boxes (UPSXML)

Locked

Views: 1,282

Results 1 to 4 of 4
This thread is locked. New replies are disabled.
18 Dec 2009, 12:16 PM
#1
bobthemolder avatar

bobthemolder

Zen Follower

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

Number of Boxes (UPSXML)

Using ZenCart 1.3.8 with UPSXML module. I'm looking to set it so that every 22lbs, we use a box (rounded up).

Been through a few of the shipping modules but can't figure out where to put it. I basically need:

$boxesToShip = ceil($total_weight/22);

But I don't know where to put it?

19 Dec 2009, 2:54 PM
#2
ajeh avatar

ajeh

Oba-san

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

Re: Number of Boxes (UPSXML)

The Tare and Boxes are computed in the shipping class file ...

But before you change the code, what happens if you just put in that the Maximum Weight shipped is 22 in the Shipping/Packaging so the boxes break at 22 lbs ... :unsure:

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!

20 Dec 2009, 9:24 AM
#3
bobthemolder avatar

bobthemolder

Zen Follower

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

Re: Number of Boxes (UPSXML)

Ajeh:

The Tare and Boxes are computed in the shipping class file ...

But before you change the code, what happens if you just put in that the Maximum Weight shipped is 22 in the Shipping/Packaging so the boxes break at 22 lbs ... :unsure:
That works. The way it's defined/explained in the admin section, it makes it seem as though you won't ship ANYTHING over that weight, not that that is the maximum box weight.

Thank you.

17 Nov 2010, 11:09 PM
#4
sethaholic avatar

sethaholic

New Zenner

Join Date:
Oct 2010
Posts:
5
Plugin Contributions:
0

Re: Number of Boxes (UPSXML)

I am having a problem with Zen Cart/UPS splitting up into # of boxes based on total weight divided by maximum weight.

I am a wholesaler shipping by case. I have already assigned each product with their own correct billable weight. UPS calculates shipping correctly if customer buys only one case. However, the problem is when they order several cases, UPS would either quote it as one big box or split it up into several different boxes.

For example, my product weighs 30 pounds. I set my max weight to 50.

If customer orders 4 cases...it should say 4 pkgs x 30 lbs.
But UPS divides it into 3 pkgs x 40 lbs, which does not reflect the true price.

Anyone know how to change the code in the UPS shipping module to have each product packaged by itself and it's own weight instead of having a total weight / max weight?

The shipping class has the following code:

if ($shipping_weight > SHIPPING_MAX_WEIGHT) { // Split into many boxes
// $shipping_num_boxes = ceil($shipping_weight/SHIPPING_MAX_WEIGHT);
$zc_boxes = zen_round(($shipping_weight/SHIPPING_MAX_WEIGHT), 2);
$shipping_num_boxes = ceil($zc_boxes);
$shipping_weight = $shipping_weight/$shipping_num_boxes;
}

So instead of having shipping_weight/Shipping_max_weight....

can we do something like "shipping_weight" divided by "# of products"?

Thanks in advance!