[ic] usertag help?
Brian J. Miller
brian at endpoint.com
Wed Apr 19 11:17:01 EDT 2006
tom wrote:
> 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?
>
In general a shipping usertag like this would be added to the
shipping.asc file under a new shipping mode. For instance I have used:
SPECIAL Special Shipping for Mail Drops weight 0 99999999 f
[mailing-service-shipping-calc all=1] { 'free' => 1, }
On a site. In my case when an item that causes the special shipping
calculation to be used gets added I set mv_shipmode=SPECIAL, and for the
most part things should just work, since the [shipping] tag, and
associated work off the shipping scheme designated in shipping.asc. See
item 7 here:
http://www.icdevgroup.org/interchange-doc-5.2.0/frames/icdatabase_frames.html
HTH,
Brian J. Miller
End Point Corp.
> 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
> _______________________________________________
> interchange-users mailing list
> interchange-users at icdevgroup.org
> http://www.icdevgroup.org/mailman/listinfo/interchange-users
>
>
More information about the interchange-users
mailing list