Zen Cart Logo
Forums / General Questions / Adding multiple items to cart at once

Adding multiple items to cart at once

Locked

Views: 1,565

Results 1 to 8 of 8
This thread is locked. New replies are disabled.
1 May 2008, 10:00 PM
#1
brandan avatar

brandan

New Zenner

Join Date:
Aug 2007
Posts:
11
Plugin Contributions:
0

Adding multiple items to cart at once

Perhaps I'm just no good with forum searches, but I have been looking for the past twenty minutes. My goal is to create a page with a list of specific items. This page will offer the user the ability to dynamically update the quantities of each item via a text box (I know, it's oh-so clever), and when the form is submitted it will be processed and add the chosen items to the shopping cart.

I've looked through the Zen-Cart API and didn't notice any functions for manipulating the shopping cart in this manner, and the only forum topic I found even closely related is long dead and utterly uninformative.

Is there any way for me to add more than one item to a shopping cart at once? Thanks in advance.

1 May 2008, 10:06 PM
#2
steven300 avatar

steven300

Totally Zenned

Join Date:
Jan 2008
Posts:
1,564
Plugin Contributions:
1

Re: Adding multiple items to cart at once

You mean kind of like the New Products listing?

2 May 2008, 11:36 AM
#3
stevesh avatar

stevesh

Black Belt

Join Date:
Feb 2005
Location:
Lansing, Michigan USA
Posts:
19,793
Plugin Contributions:
2

Re: Adding multiple items to cart at once

Zencart does this natively with the right admin settings, as long as the list you're talking about is a product list (Category, New, Featured, etc.).

2 May 2008, 11:57 AM
#5
fairestcape avatar

fairestcape

Totally Zenned

Join Date:
Mar 2008
Location:
Cape Town & London (depends on the season)
Posts:
2,957
Plugin Contributions:
0

Re: Adding multiple items to cart at once

... and yes... you can pre-populate the MODEL NUMBER field with selected model numbers - or have it blank as we do...

2 May 2008, 2:03 PM
#6
brandan avatar

brandan

New Zenner

Join Date:
Aug 2007
Posts:
11
Plugin Contributions:
0

Re: Adding multiple items to cart at once

I'm not sure if what I need is anything like the new products listing. I'm fairly inexperienced with Zen-Cart at this point.

The issue is, the list would have to have custom header text (an introduction, of sorts), and would need some sort of validation in the form of checking the collective weight of products to ensure they meet a specific requirement (completely separate from the main cart) before allowing the selections to be added to the cart.

What I need is to add the items to the cart with specific attributes, and it would seem almost necessary to me that there be a function for adding items to the cart already. Otherwise development would be pretty limited, no?

I will check out that module, fairestcape. If anything it will at least give me a shove in the right direction. Thanks.

2 May 2008, 2:29 PM
#7
brandan avatar

brandan

New Zenner

Join Date:
Aug 2007
Posts:
11
Plugin Contributions:
0

Re: Adding multiple items to cart at once

from looking at the quick order module, it appears as though adding items to the cart is as simple as manipulating a session variable. now to find out exactly what all is stored in there!

2 May 2008, 3:04 PM
#8
brandan avatar

brandan

New Zenner

Join Date:
Aug 2007
Posts:
11
Plugin Contributions:
0

Re: Adding multiple items to cart at once

i'm not trying to flood my own thread, but apparently i can only edit my posts for 7 minutes after i make them (that's such an arbitrary restriction). anyway, it appears that the key of the array the product attributes are stored in is a salted md5 hash? does anybody have any insight into this?