Page 1 of 2 12 LastLast
Results 1 to 10 of 11
  1. #1
    Join Date
    Jun 2008
    Posts
    63
    Plugin Contributions
    0

    Default Shipping box numbers

    Hi all

    I set the following as:

    Maximum Package Weight: 0.2
    Products Shipping Weight: 0.2
    Shipping rates to zone 1: 0.5:8.50,1:9,2:9.5,3:10 and so on.

    I can explain the problem better in the following:

    The customer buys 1 item: 1 x 0.2 lb, $8.5
    The customer buys 2 items: 2 x 0.2 lb, $17
    The customers buys 3 items: 4 x 0.15 lb, $34
    For four items it is the same as above
    The customer buys 5 items: 5 x 0.2 lb, $42.5

    In the Delivery Information part of the Checkout process, I want the weight to be displayed as 0.2 lb no matter how many items the customer buys. However, in the example above it doesn’t show the correct weight in the third one. Also when 12 items are purchased, it displays as 0.18. Secondly, is it possible to calculate the shipping cost not like above but as I stated in the shipping rates zone? For instance, when 1 or 2 items are purchased, the customer will get charged only $8.5, if it is 3 items, $9, more than 1 lb $9.5 and so on.

    Any suggestion appreciated.

  2. #2
    Join Date
    Sep 2003
    Location
    Ohio
    Posts
    69,402
    Plugin Contributions
    6

    Default Re: Shipping box numbers

    Do you only use Table Rate table/Zone Rate zones shipping module?

    Are all of your Products 0.2 in weight? Or is that just your example?
    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: v1.5.5]
    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!

  3. #3
    Join Date
    Jun 2008
    Posts
    63
    Plugin Contributions
    0

    Default Re: Shipping box numbers

    Hi Ajeh

    I just use Zone Rate Module and yes, it is just an example. In the near future, however, when I finish the book and deal with the real products, the weight of each one will change a bit. Just for now, let's get stick to 0.2.

  4. #4
    Join Date
    Sep 2003
    Location
    Ohio
    Posts
    69,402
    Plugin Contributions
    6

    Default Re: Shipping box numbers

    There is a precision error on the php ceil() function ... so you need to change the shipping.php class file:
    /includes/classes/shipping.php

    to read:
    Code:
          if ($shipping_weight > SHIPPING_MAX_WEIGHT) { // Split into many boxes
    //        $shipping_num_boxes = ceil($shipping_weight/SHIPPING_MAX_WEIGHT);
            $shipping_num_boxes = zen_round($shipping_weight/SHIPPING_MAX_WEIGHT);
            $shipping_weight = $shipping_weight/$shipping_num_boxes;
          }
    This appears to fix the precision issues on things so small ...
    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: v1.5.5]
    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!

  5. #5
    Join Date
    Jun 2008
    Posts
    63
    Plugin Contributions
    0

    Default Re: Shipping box numbers

    Linda thanks a lot for the help. Now 0.2 lb thing remains the same.

    However there is a small issue left. ZC still adds $8.5 for each 0.2 lb. If the shipping rates are configured as 0.5:8.50,1:9,1.5:9.5....., then for two items $8.5 should be charged instead of $17 and $9 for 3 items instead of $25.5, etc. The only way I can resolve this issue is to change the 'Maximum Package Weight' to a higher value i.e. 50. But in this case the number of packages is shown as 1. Is there a way to accomplish this without changing 0.2 to 50?

  6. #6
    Join Date
    Sep 2003
    Location
    Ohio
    Posts
    69,402
    Plugin Contributions
    6

    Default Re: Shipping box numbers

    The Zone Rate zones and Table Rate table are using the definitions based on the box weight ...

    Set the first rate to charge 8000, example:
    0.5:8000,1:9,2:9.5,3:10

    Now add quantity 10 of 1 or more Products that weight .2 ...

    That makes a total of 10 x .2 = 2 ...

    However ...

    2 / .2 maximum weight is 10 x .2 ... so it uses the .2 rate x 10 or 8000 x 10 ... for $80,000 ...

    It never sees the other rates as the rates are based on the Box Sizes which is determined from the Maximum Weight ...

    If what you are really trying to do is base your rates on the Item Count of Products, then try switching that to price things by Item Count rather than weight and re-do the quantity breaks ...
    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: v1.5.5]
    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!

  7. #7
    Join Date
    Jun 2008
    Posts
    63
    Plugin Contributions
    0

    Default Re: Shipping box numbers

    Well, switching it to item count will cause problems for the products different in weight. Imagine that the customer pays the same shipping price for a 1lb and 3lb-item. I guess there is not a work around for this problem at least for now (hope it will be). Thanks anyway Linda, you have been very helpful as always.

  8. #8
    Join Date
    Sep 2003
    Location
    Ohio
    Posts
    69,402
    Plugin Contributions
    6

    Default Re: Shipping box numbers

    Another way to do this is the Per Weight Unit where the products_weight is used as the shipping cost on a Per Item per quantity ...

    So if you set the Product weight to: 2

    and then order:
    1 x 2 = 2.00
    2 x 2 = 4.00
    3 x 2 = 6.00
    etc.

    So if you set the Unit Rate on the Per Unit perweightunit to 1.00 and have 1 Product in the cart with quantity 1 with a weight of .20 and 1 Product in the with quantity 2 with a weight of 2.50 you would get:
    1 x 1 x .20 = .20
    1 x 2 x 2.50 = 5.00

    for a total of 5.20 ...

    NOTE: to use this, set the Maximum Weight to: 5000 and the Tare Weights to 0:0 ...
    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: v1.5.5]
    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. #9
    Join Date
    Jun 2008
    Posts
    63
    Plugin Contributions
    0

    Default Re: Shipping box numbers

    Per Weight Unit seems to get the job done but it doesn't display the number of boxes and weight i.e. 1 x 0.2, 2 x 0.4. Is this a normal behaviour of this module or something missing?

  10. #10
    Join Date
    Sep 2003
    Location
    Ohio
    Posts
    69,402
    Plugin Contributions
    6

    Default Re: Shipping box numbers

    Per Weight Unit does not list the number of boxes as there really isn't a method to know how many are in the boxes based on the fact that products_weight is used as a shipping cost and not a weight that can be divided by the Maximum Weight and have any meaning ...
    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: v1.5.5]
    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!

 

 
Page 1 of 2 12 LastLast

Similar Threads

  1. v151 Restrict Qty Box input to numbers
    By wacamatic in forum Templates, Stylesheets, Page Layout
    Replies: 3
    Last Post: 19 Nov 2012, 04:43 AM
  2. Text Box Numbers
    By straid in forum Basic Configuration
    Replies: 1
    Last Post: 23 Jun 2008, 03:38 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
disjunctive-egg
Zen-Cart, Internet Selling Services, Klamath Falls, OR