Page 2 of 3 FirstFirst 123 LastLast
Results 11 to 20 of 24
  1. #11
    Join Date
    Jan 2008
    Location
    Switzerland
    Posts
    38
    Plugin Contributions
    0

    Default Re: Can you have a handling fee for ONE product or category?

    Great!

    I don't know PHP that well, just a little from looking at the code in my site. Do you know what I need to change so that the syntax is correct for either/or products as opposed to both (+)...

    $extra_charge = ($chk_product_1393 * 7.50) + ($chk_product_1394 * 7.50);
    Tracey Haas
    Temporary Tattoos

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

    Default Re: Can you have a handling fee for ONE product or category?

    You could use instead of:
    Code:
    $extra_charge = ($chk_product_1393 * 7.50) + ($chk_product_1394 * 7.50);
    Code:
    if ($chk_product_19 > 0  || $chk_product_32 > 0) {
      $extra_charge = 7.50;
    } else {
      $extra_charge = 0.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: 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. #13
    Join Date
    Jan 2008
    Location
    Switzerland
    Posts
    38
    Plugin Contributions
    0

    Default Re: Can you have a handling fee for ONE product or category?

    Thanks so much Linda, I really appreciate it! It works perfectly now
    Tracey Haas
    Temporary Tattoos

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

    Default Re: Can you have a handling fee for ONE product or category?

    Thanks for the update that this is now working for you ...
    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. #15
    Join Date
    May 2011
    Posts
    67
    Plugin Contributions
    0

    Default Re: Can you have a handling fee for ONE product or category?

    Hey Ajeh,

    I'd like to do the same thing but with the ups module. If any products from category 2 are in the shopping cart, I'd like to add an extra charge of $10.
    I don't really know what I'm doing but I tried the following code. My changes are in red.

    $cost = preg_replace('/[^0-9.]/', '', $cost);
    // bof: add accessories charge
    $chk_categories = $_SESSION['cart']->in_cart_check('master_categories_id','2');
    $extra_charge = ($chk_categories * 10.00);


    $methods[] = array('id' => $type,
    'title' => $this->types[$type],
    'cost' => ($cost * $shipping_num_boxes) + (MODULE_SHIPPING_UPS_HANDLING_METHOD == 'Box' ? MODULE_SHIPPING_UPS_HANDLING * $shipping_num_boxes : MODULE_SHIPPING_UPS_HANDLING + $extra_charge) );

    This didn't change anything on the shipping totals even when I had products from category 2 in the shopping cart.
    Any suggestions?

    All your posts in various threads have been very helpful-- thanks for that!

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

    Default Re: Can you have a handling fee for ONE product or category?

    Is categories_id 2 the master_categories_id or is it the parent_id for the Products/Categories that need the extra fee?

    A link to your site might also be helpful to be able to check the layout of your shop ...
    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. #17
    Join Date
    May 2011
    Posts
    67
    Plugin Contributions
    0

    Default Re: Can you have a handling fee for ONE product or category?

    Sorry, I'm not sure what you mean. The categories id 2 is the category id for my accessories. I want all products within this category to have the extra shipping charge when UPS is used as the shipping method.

    My website is ---premierwagons.com---

    Thank you!

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

    Default Re: Can you have a handling fee for ONE product or category?

    What happens if you change the cost calculation to:
    Code:
    'cost' => ($cost * $shipping_num_boxes)  + $extra_charge + (MODULE_SHIPPING_UPS_HANDLING_METHOD == 'Box' ? MODULE_SHIPPING_UPS_HANDLING * $shipping_num_boxes : MODULE_SHIPPING_UPS_HANDLING) );
    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. #19
    Join Date
    May 2011
    Posts
    67
    Plugin Contributions
    0

    Default Re: Can you have a handling fee for ONE product or category?

    That worked! That is, when products from category two are shipped via UPS, an extra $10 are added to shipping cost.

    Would there be a way to apply this extra charge only once (even if multiple quantities of products from category two are in cart)?
    Perhaps the coding would be something like this? (albeit my code in red seems a little redundant) :

    $cost = preg_replace('/[^0-9.]/', '', $cost);
    // bof: add accessories charge
    $chk_categories = $_SESSION['cart']->in_cart_check('master_categories_id','2');
    $extra_charge = ($chk_categories * 10.00);
    if ($chk_categories > 0) {
    $extra_charge = 10.00;
    }




    Ideally, (but not totally essential) I'd like to have it set up so that the extra charge is only applied once for a quantity of 3 accessories. If the quantity goes over three, add extra charge again. If it goes over 6, the charge would have been added three times...

    Is the coding for this simple enough?

    Thanks again for your time.

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

    Default Re: Can you have a handling fee for ONE product or category?

    You could try:
    Code:
    $cost = preg_replace('/[^0-9.]/', '', $cost);
    // bof: add accessories charge
    $chk_categories = $_SESSION['cart']->in_cart_check('master_categories_id','2');
    $extra_charge = (ceil($chk_categories/3) * 10.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: 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 2 of 3 FirstFirst 123 LastLast

Similar Threads

  1. Replies: 5
    Last Post: 19 Sep 2012, 03:49 AM
  2. Per item handling charge for one category?
    By dkervin in forum Built-in Shipping and Payment Modules
    Replies: 9
    Last Post: 16 Nov 2010, 05:38 AM
  3. Handling Fee for One Zone.
    By laydiefa in forum Built-in Shipping and Payment Modules
    Replies: 0
    Last Post: 4 Jun 2008, 04:44 AM
  4. Individual Handling Fee for Product
    By edusupport in forum Built-in Shipping and Payment Modules
    Replies: 0
    Last Post: 7 Feb 2008, 05:20 PM
  5. Freeshipper Handling Fee - What have I done wrong?
    By fancypants in forum Built-in Shipping and Payment Modules
    Replies: 7
    Last Post: 11 Jul 2007, 06:03 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