[ic] Re: adding extra information into the shopping cart structure

John Allman interchange-users@icdevgroup.org
Thu Oct 10 10:33:00 2002


John Allman wrote:

>
> perhaps there's some way to access the appropriate part of the 
> shopping cart in perl? i'm assuming as the basket page iterates 
> through the contents of the cart there is some variable which keeps 
> track of the current item - a counter or something?


The following appears to work - but it's filthy filthy code. I dont know 
how to call item-increment in perl. i tried $Tag->item_increment() but 
that didn't work (which isn't surprising since i just made it up). Can 
you point me towards a less horrid way of doing this?

[perl]return 
$Session->{carts}->{main}[[item-increment]-1]->{quickorder}[/perl]