The Code

This section details the code involved in the script. The descriptions are of a high level, as most of the topics have already been covered. Additional descriptions are provided when new topics are introduced.

cart.sql

cart.sql is the SQL statement required to set up the database for use with this application.

Script 5-1. cart.sql
						1.  create table customers (
 2.  id INT NOT NULL,
 3.  first VARCHAR(32),
 4.  mi CHAR(2),
 5.  last VARCHAR(32),
 6.  address1 VARCHAR(64),
 7.  address2 VARCHAR(64),
 8.  city VARCHAR(32),
 9.  state CHAR(2),
10.  zip VARCHAR(10),
11.  country VARCHAR(32),
12.  shiptobilling VARCHAR(5),
13.  ship_address1 VARCHAR(64),
14.  ship_address2 VARCHAR(64),
15.  ship_city VARCHAR(32),
16.  ship_state CHAR(2),
17. ship_zip VARCHAR(10), ...

Get Advanced PHP for Web Professionals now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.