Retail Site Project

You will implement an on-line web store. We've all browsed countless sites like this: Amazon, BestBuy, HomeDepot, etc., so you've plenty of examples to build from. Your store should feature:

  1. User-specific login process. Users should be able to create a new login id (along with a password). These will be stored in an SQL database and used for subsequent logins.
  2. A mechanism for the user to create and modify their shipping information, password, etc.
  3. Memory of previous orders by the user ("on your previous visit you ordered....")
  4. A "shopping cart", where users can indicate which goods they want to purchase. The contents of the shopping cart should be lost only when the user logs out, or the browser session terminates.
  5. Users should be able to place items into the shopping cart through the GUI with no typing required.
  6. A "checkout" method, wherein the users can provide credit card and shipping information to purchase the materials in the shopping cart.
  7. A mechanism for browsing the inventory, and for searching the inventory for items by name (use regular expressions).
  8. All inventory information must be stored in the database--not hardcoded in html files.

Your project must:

  1. Result in the development of an interactive web-site.
  2. Make use of a MySQL database via PHP. Client use of the web-site should result in additions, modifications, and deletions to the database. Use a mysql database to store information about each client, and the information about each item for sale. Thus, adding an item to the database should change what is displayed on the web pages on a subsequent visit.
  3. Each item should have a name, a description, and a price.
  4. When displaying the shopping cart, show the cost of the sum of the items in the cart. Provide a mechanism for removing items from the cart before the order is completed.
  5. Provide an adequate level of security. Individual users of your web-site should have some kind of password-protected entry, to maintain privacy. Different users should not be able to access each other's data. You should store the passwords in the database.
  6. Consist of source code written in HTML, Javascript, PHP, and SQL.

Timeline:

Part 1: Submit a console transcript of your interaction with a MySQL database containing at least 10 items representing the merchandise for your store. You'll need to encode name, a description, and a price. The database should also contain information for at least three clients. You'll need to encode a name, an address, a password, and an encoding of at least one prior purchase. (You should figure out how you will encode prior purchases. Maybe a date, and a list of item IDs and the number of each? Consider how the book's "cars" example encoded the equipment that was in each car.)

Part 2: Submit your project.

Graduate Student Requirement

If you are taking this course for graduate credit your system must provide an administrator login that allows the administrator to manage the site's inventory.

The inventory should keep track of how many instances of each item remain in inventory via your database. (Initially, you should just provide a small number of each.) When a "buyer" "purchases" items, the item count should be reduced accordingly in the inventory. You must also provide a mechanism for an administrator to log onto a web page that will allow for the inventory of the store to be modified. The administrator must be able to:

Extra Credit

Provide an image to be associated with each item. The images should be displayed, where appropriate, to both the administrator and to shoppers. The administrator's page must allow images to be associated with new items.

Submitting Your Project

See the directions on Canvas.

If you are providing images, those should be in a subdirectory named "Images". Any file references (including those to image files) should use relative path names. E.g., "Image/bob.jpg" not "C:/Documents/myDir/Image/bob.jpg".

The file db.sql should be created via the "mysqldump" command, so that I can create your database by executing source 'db'; at the MySQL command line prompt. Here's an example console terminal command for dumping a database named "cars":

mysqldump --databases cars > db.sql

Make sure you use the "--databases" parameter. This will result in db.sql containing CREATE DATABASE and USE instructions.