O'Reilly logo

PHP 5 e-commerce Development by Michael Peacock

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Considerations for our shopping basket

We discussed a number of considerations we need to take into account within our shopping basket in Chapter 4, Product Variations and User Uploads. Let's recap on those, and discuss how we shall implement those suggestions.

  • Stock levels: In some cases, we need to determine if there is sufficient stock when a customer adds a product to their basket. When we add a product to the basket, we can simply query the products database, and ensure the level in stock is either more than the quantity the customer wishes to purchase, or is not relevant for that product (for example digital delivery products, services, and so on).
  • Product variations: When a customer adds a product variation to their basket, we need to record ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required