[ic] Payment.pm
Dwayne Holmberg
interchange-users@icdevgroup.org
Wed Jun 4 14:41:00 2003
On Wed, 2003-06-04 at 13:43, Cameron G wrote:
> > On Tue, 2003-06-03 at 07:21, Cameron G wrote:
> > > Let us consider this snippet of code from Payment.pm
> > >
> > > foreach $key (keys %map) {
> > > $actual{$key} = $vref->{$map{$key}} || $cref->{$key}
> > > and next;
> > > my $secondary = $key;
> > > next unless $secondary =~ s/^b_//;
> > > $actual{$key} = $vref->{$map{$secondary}} ||
> > > $cref->{$map{$secondary}};
> > > }
> > >
> > > am i to believe that when creating the %actual hash, it will put the
> billing
> > > details in in place of the shipping details if the customer has filled
> them
> > > in?
> >
> > Yep, you are.
> >
> > --
> > Dwayne Holmberg
> > Iconys Informatica, Inc.
> >
>
> Ok, that's what i thought too, but my tests seem to say: no, that's not
> exactly how it works. I seem to just end up with a bunch of empty shipping
> details and all the billing details filled out as normal.
hmmm...sorry, read the code wrong and out of context. A quick check of
payment modules (including the one I'm working on ;) ) indicates that
you should use the billing addresses (eg $actual->{'b_zip'}) for your
billing address. The values for billing fields are copied over.
--
Dwayne Holmberg
Iconys Informatica, Inc.
http://iconys.com
Ph: 780.423-1700
Fax: 780.423-1775