[ic] discount group follow up

Blair Campbell interchange-users@icdevgroup.org
Thu Oct 31 15:37:00 2002


sounds straight forward...here is the page where exactly should the code go?

[perl tables="country products"]
    my $db = $Db{country} or return;
 
    my $domestic = $Variable->{DOMESTIC_SHIPPING} || 'US CA';
    $domestic =~ s/\W+/ /g;
    my @dom = grep /\S/, split /\s+/, $domestic;
    my %dom;
    @dom{@dom} = @dom;
    my $modes;
    if($Values->{country}) {
 $modes = tag_data('country', 'shipmodes', $Values->{country});
 @modes = grep /\S/, split /[\s,\0]+/, $modes;
    }
    
    delete $Scratch->{only_download};
    my $hardgoods;
    for(@$Items) {
 next if tag_data('__ProductFiles_0__', 'download', $_->{code});
 $hardgoods = 1;
    }

    ! $hardgoods and $Scratch->{only_download} = 1;

    return unless @modes;
    my %modes;
    @modes{@modes} = @modes;

    if(! $modes{$Values->{mv_shipmode}}) {
     $Values->{mv_shipmode} = shift @modes;
    }
    return;
[/perl]

<table width="95%">
........etc
----- Original Message ----- 
From: "Michael Goldfarb" <mikeg@contactdesigns.com>
To: <interchange-users@icdevgroup.org>
Sent: Thursday, October 31, 2002 11:55 AM
Subject: RE: [ic] discount group follow up


> >I have found some info on discounts at:
> >http://www.icdevgroup.org/i/dev/docfly.html?mv_arg=ictags04.20
> >
> >It seems straight forward, however where do I insert this code?
> >
> >To apply a straight 20% discount to all items:
> >
> >    [discount ALL_ITEMS] $s * .8 [/discount]
> >
> >Thanks
> >
> >Blair Campbell
> 
> Just put it at the top of the checkout.html page and you should be good
> to go.
> 
> 
> _______________________________________________
> interchange-users mailing list
> interchange-users@icdevgroup.org
> http://www.icdevgroup.org/mailman/listinfo/interchange-users
>