Only Charge Shipping to International Customers

jodycollierjodycollier Member
in Help edited January 2013
FoxyPeeps-

I'm looking for a way to make certain items' shipping free for domestic customers, while charging international customers.

Is there a code snippet [exception] sort of tag that that I could use on the item? I'd just be hard coding it into a few items on a page-by-page basis.

Thanks!

Jody
http://welding-tv.com/tig-finger
Comments
  • fc_adamfc_adam FoxyCart Team
    Hey Jody,

    So with your store you're set up to use live rates. To achieve conditional free shipping for some products only domestically, you'll need to add some javascript to your checkout which works out what shouldn't be charged for shipping and allowing for that.

    With live rates, if you have a product that is exempt from shipping you basically need to remove it's weight from the total weight of the cart that is send to the live shipping endpoint. That then removes it's weight from being factored into the shipping costs. You also need to have a check that if only free shipping items are in the cart, that you just offer free shipping as a rate for the customer to check.

    I've actually written something similar previously - this should get you over the line if I'm understanding you correctly:

    Follow the instructions here: http://wiki.foxycart.com/snippets/shipping/live_rate_shipping_modification

    And when it comes time for the custom logic, use this:
    http://pastie.org/private/d4jfz761dy3hcjzcm0q

    And paste this right before the snippet detailed in the steps on that wiki page: http://pastie.org/private/kp29k0bnph8hvzgcsfpe0q

    That should get you there. Note I haven't tested this, so make sure you test it thoroughly. Also, note that this script relies on a product option called 'freedomestic' being set to 'true'. You can change 'freedomestic' to something else at the start of the first pastie I linked to.
  • @fc_adam ,

    This looks perfect. Thank you so much. I'll test it and let you know how it works.

    Cheers,

    Jody
Sign In or Register to comment.