radical hacks UPS Intergation sent in the following hack...

Here's another Perl library and documentation that I've been working on. "ups-lib.pl" is used to implement the UPS Quick Cost Calculator service, available from www.ups.com, into the eXtropia.com Web Store program.

I've tested this library for over a couple months now and have found it to be a solid bit of code. Feel free to post it on the hacks page so others can take advantage of the UPS Quick Cost Calculator service. Unfortunately, the code has only been tested for shipping in the United States. For shipping to other countries, the code would have to be modified.

Version update for the UPS calculation sent in by Jeff Walters on May 13, 2000!

Get both the library file and documentation file here!

Oppssss......Jeff Walters found a minor bug in his hack so he sent in the fix on June 13, 2000! So here it is as quoted from his email to Selena Sol.

   I just notice the other day when I was testing out my UPS cost subroutines that the measured field was not taking in consideration the "quantity".
Maybe I have an old version, or maybe I messed that up. Either way, I thought I would let you know about it.
You'll have to make this change if you want the measured field (weight = for example) to add up quantities correctly.

Change

      if ($display_index =3D=3D $sc_cart_index_of_measured_value)=20
        {
        $total_measured_quantity +=3D $cart_fields[$display_index];
        }
To
      if ($display_index =3D=3D $sc_cart_index_of_measured_value)=20
        {
        $total_measured_quantity +=3D =
        $cart_fields[$display_index]*$quantity;
        }