Re: creating a shopping cart.

From: Date: Sat, 01 Oct 2005 18:33:54 +0000
Subject: Re: creating a shopping cart.
References: 1 2 3  Groups: php.general 
Request: Send a blank email to php-general+get-223492@lists.php.net to get a copy of this message
On Sat, 2005-10-01 at 11:41, adriano ghezzi wrote: > you need a db based approach, just setup a couple of tables in mysql > > items table > one record per item > > current cart table > one record per each item added to cart with unique session id > > order table > one record per each item ordered with unique order id > > you'll transfer records here from current cart when user checkout A DB approach is nice, but not necessary. Serialization of a shopping cart array that contains the contents of the cart is sufficient. While a DB is a natural solution, I've heard of systems that use the file system or even email the request to a fulfillment address. Cheers, Rob. -- .------------------------------------------------------------. | InterJinn Application Framework - http://www.interjinn.com | :------------------------------------------------------------: | An application and templating framework for PHP. Boasting | | a powerful, scalable system for accessing system services | | such as forms, properties, sessions, and caches. InterJinn | | also provides an extremely flexible architecture for | | creating re-usable components quickly and easily. | `------------------------------------------------------------'

« previous php.general (#223492) next »