User Guide

Shopping Cart Reference 169
Shopping Cart Interactions
The Shopping Cart Contracts allow you to add items to and update items in a
shopping cart, insert shopping cart data into a database, and perform a couple of
miscellaneous display functions based on data in the shopping cart.
Add item from [Recordset] to [ShoppingCart] when [button]
is clicked
This is a contract between a basement Shopping Cart SmartElement, a submit
button, and a Recordset that provides source data to the Shopping Cart. When
the button is clicked, an item corresponding to the current record in the Recordset
is added to the Shopping Cart. With this contract, the quantity for the added item
is one. Parameters for controlling redirection after adding are described below:
Parameters:
Redirect After Adding determines whether you want to redirect after adding
the item or not.
NewItemRedirect specifies the target page for redirecting after an item is
successfully added to the cart
Redirect if Already in Cart toggles whether you want to redirect to a message
page if the selected item is already in the cart.
AlreadyInCartRedirect specifies the target page for redirecting if an item is
already in the cart
Participants:
ShoppingCart
Recordset
Button (any clickable object)