| Contents | 5 |
---|
| About the Authors | 13 |
---|
| About the Technical Reviewer | 14 |
---|
| Introduction | 15 |
---|
| Chapter 1 Starting an E-Commerce Site | 20 |
---|
| Deciding Whether to Go Online | 20 |
| Getting More Customers | 21 |
| Making Customers Spend More | 21 |
| Reducing the Costs of Fulfilling Orders | 22 |
| Making Money | 22 |
| Considering the Risks and Threats | 23 |
| Designing for Business | 24 |
| Phase I: Getting a Site Up | 25 |
| Phase II: Creating Your Own Shopping Cart | 25 |
| Phase III: Processing Orders | 26 |
| The Balloon Shop | 27 |
| Summary | 28 |
| Chapter 2 Laying Out the Foundations | 29 |
---|
| Designing for Growth | 30 |
| Meeting Long-Term Requirements with Minimal Effort | 30 |
| The Magic of the Three-Tier Architecture | 31 |
| Choosing Technologies and Tools | 36 |
| Using ASP.NET 2.0 | 37 |
| Using C# and VB .NET | 41 |
| Using Visual Studio 2005 and Visual Web Developer 2005 Express Edition | 41 |
| Using SQL Server 2005 | 42 |
| Following Coding Standards | 44 |
| Creating the Visual Web Developer Project | 45 |
| Implementing the Site Skeleton | 49 |
| Building the First Page | 51 |
| Adding the Header to the Main Page | 56 |
| Creating the SQL Server Database | 59 |
| Downloading the Code | 61 |
| Summary | 61 |
| Chapter 3 Creating the Product Catalog: Part I | 62 |
---|
| Showing Your Visitor What You ve Got | 62 |
| What Does a Product Catalog Look Like? | 63 |
| Previewing the Product Catalog | 64 |
| Roadmap for This Chapter | 67 |
| Storing Catalog Information | 69 |
| Understanding Data Tables | 70 |
| Creating the Department Table | 78 |
| Communicating with the Database | 80 |
| Speaking the Database Language | 81 |
| Creating Stored Procedures | 85 |
| Adding Logic to the Site | 87 |
| Connecting to SQL Server | 88 |
| Issuing Commands and Executing Stored Procedures | 91 |
| Implementing Generic Data Access Code | 93 |
| Catching and Handling Exceptions | 95 |
| Sending Emails | 98 |
| Writing the Business Tier Code | 98 |
| Displaying the List of Departments | 107 |
| Preparing the Field: Themes, Skins, and Styles | 107 |
| Displaying the Departments | 111 |
| Adding a Custom Error Page | 117 |
| Summary | 121 |
| Chapter 4 Creating the Product Catalog: Part II | 122 |
---|
| Storing the New Data | 122 |
| What Makes a Relational Database | 123 |
| Enforcing Table Relationships with the FOREIGN KEY Constraint | 127 |
| Adding Categories | 128 |
| Adding Products | 133 |
| Querying the New Data | 139 |
| Retrieving Short Product Descriptions | 139 |
| Joining Data Tables | 140 |
| Showing Products Page by Page | 142 |
| Writing the New Stored Procedures | 146 |
| Using ADO.NET with Parameterized Stored Procedures | 152 |
| Using Input Parameters | 152 |
| Using Output Parameters | 152 |
| Stored Procedure Parameters Are Not Strongly Typed | 153 |
| Getting the Results Back from Output Parameters | 153 |
| Completing the Business Tier Code | 153 |
| Implementing the Presentation Tier | 164 |
| Displaying the List of Categories | 165 |
| Displaying Department and Category Details | 170 |
| Displaying Product Lists | 174 |
| Summary | 184 |
| Chapter 5 Searching the Catalog | 185 |
---|
| Choosing How to Search the Catalog | 185 |
| Teaching the Database to Search Itself | 187 |
| Implementing a Custom Search Engine | 187 |
| Introducing the SearchCatalog Stored Procedure | 191 |
| Implementing Paging | 193 |
| Writing the Code | 194 |
| Implementing the Business Tier | 198 |
| Implementing the Presentation Tier | 200 |
| Creating the Search Box | 201 |
| Displaying the Search Results | 207 |
| Searching Smarter | 211 |
| Summary | 213 |
| Chapter 6 Improving Performance | 214 |
---|
| Handling Postback | 214 |
| Managing ViewState | 218 |
| Using Output Cache | 221 |
| Summary | 223 |
| Chapter 7 Receiving Payments Using PayPal | 224 |
---|
| Considering Internet Payment Service Providers | 225 |
| Getting Started with PayPal | 226 |
| Integrating the PayPal Shopping Cart and Checkout | 227 |
| Using the PayPal Single Item Purchases Feature | 233 |
| Summary | 234 |
| Chapter 8 Catalog Administration | 235 |
---|
| Preparing to Create the Catalog Administration Page | 235
|