[ic] usertag help?

tom giftbound at verizon.net
Tue Apr 18 20:05:13 EDT 2006


how do I get this to work? I have the following usertag for shipping what it does it pulls the zip code from the wharehouse im shipping from however how do I call it and what page?

Got this from:
http://www.icdevgroup.org/pipermail/interchange-users/2002-April/020362.html

 UseModifier origin,weight

And used the following user tag.
##############################
UserTag  ship  Order  mode zip country
UserTag  ship  Routine <<EOR
sub {
        my($mode, $zip, $country) = @_;
        $country        = $::Values->{$::Variable->{UPS_COUNTRY_FIELD}}  if
! $country;
        $zip            = $::Values->{$::Variable->{UPS_POSTCODE_FIELD}} if
! $zip;
        $country = uc $country;

        my $shipping = 0;
        my $cart = $Carts->{main};
        foreach my $item (@$cart) {
           $shipping += $Tag->ups_query({
               mode => $mode,
               origin => $item->{'origin'},
               zip => $zip,
               country => $country,
               weight => $item->{'weight'},
           });
       }

        return $shipping;
}
EOR


More information about the interchange-users mailing list