I completed a website to sell clothing using Adam Khoury's eccommerce tutorial.
I have been banging my head off wall to get a drop down options for size and color to be selected by customer in products page and then when customer adds to cart, those size and color options are displayed under or in shopping cart description box.
I am using mysql to hold id on product, the product has the same id, but mutiply sizes and colors.
I relly just need a way for customers to choose they options outside of MYSQL and display them in shopping cart, so I can send the correct product.
You need 2 databases to easily accomplish this, products and options. You simply query all the options for that product and display them in a drop down box. Options need to be identified by product ID and option group so you can create a size group, color group, etc.
That's a simplistic implementation.
Learning and rolling your own cart is fun, but why not just get a free pre-built cart that has all the options you want already built and tested?
FWIW, many web hosting accounts offer a cart already installed on the server.