eCommerce Site Design

At this point a number of previous learnings can be pulled together to illustrate the integration of Web pages and workflows that tie them together. The following set of tutorials lead you through the steps for developing an online commercial Web site for selling products. This example uses the BooksDB.mdb database of books from previous tutorials. There is occasion in these examples to explore most of the considerations in developing an online store. You can view this Web site in operation by clicking the eCommerce Site link in the tutorial menu. The following illustration outlines the pages and links that comprise the site. General descriptions of these pages are given below.

Figure 13-1. Pages and workflow of eCommerce site.

Default.aspx Page

The site is built around the use of master pages, all which share a common title, menu, and search features. A book search is the basic navigation technique. A couple of ways of looking for books is provided: viewing a list of books within particular book-type categories and keyword searches for book titles, descriptions, or author names. A visitor arriving at this page is assigned a unique order number to identify this shopper.

Search.aspx Page

When the visitor clicks on a category or submits a search word, transfer is made to the Search.aspx page. The search routines produce a listing all of the books in a chosen category or all the books that match a search criterion. Links are provided for additional details about a book and its purchase on the Details.aspx page.

Details.aspx Page

Full information about a book is displayed on this page. It receives a book identification from the Search.aspx page to call up the information from the database. A button is provided for adding this book to the shopping cart by writing a record to the ShopCart table of the BooksDB.mdb database.

ShopCart.aspx Page

The shopping cart page is accessible at any time from the common menu. It lists a customer's shopping cart items stored in the ShopCart table. Opportunity is provided to change item quantities or to delete items. When the visitor is ready to purchase the books, a link is made to the CreditCheck.aspx page for order checkout.

CreditCheck.asps Page

This page simulates a credit card processing service. It is provided with a merchant ID, a customer ID, the total amount of the order, and a return URL as the destination for returning credit processing information. The page returns an order approval and customer information that is collected.

OrderCapture.aspx Page

This page receives the return information from the credit card processing service and issues an email confirmation to the customer. Transfer is then made to the SalesOrder.aspx page.

SalesOrder.aspx Page

This page displays the final sales order for the customer to confirm the sale and print a copy. The shopping cart is emptied and a new order number is assigned for additional shopping under this new number.

There are two other pages that contain scripting but do not have a visible presence. SubmitForm.aspx and ReturnOrder.aspx are intermediate script pages to transmit forms between pages.

All pages for the site are stored in the eCommerce directory, which is set up as a virtual Web directory. The site is supported by the BooksDB.mdb database, which appears inside the Databases subdirectory of the main eCommerce directory. Book pictures are in a BookPictures subdirectory.

On subsequent tutorial pages the design and coding details for this site are discussed. This application is not a fully functional eCommerce site, but it does include most of the common features that can be fleshed out to make it functional.