HTML Construction for Solution Sites
The Commerce Server Solution Sites use a technique for constructing HTML that differs from the more traditional technique in which HTML tags, content, and script are freely intermixed on Web pages. Opposed to this, nearly all of the HTML returned to browsers by the Solution Sites is produced by script.
As is the case in most large Web sites, the data itself, such as the descriptions and prices of products in the catalog, is retrieved from databases using script.
The Solution Sites take this technique further, retrieving the content that explains the data from strings that are defined centrally. This methodology has the advantage of making localization of the Web site much more straightforward.
Script is used to intermix the data, the centralized content, and the HTML tags that format both. The script produces strings, sometimes quite large, that are then written to the browser using either the Write method of the intrinsic Response object, or the abbreviated form: <%= sHTM %>
.
One of the main advantages of this technique, that builds the HTML in strings, is that the strings can be cached, thereby reducing database access. The Solution Sites use caching extensively.
The Solution Sites include a utility routine file that contains routines dedicated to helping you construct HTML. The name of this file is include\html_lib.asp.
This section contains:
- HTML Construction Methodology for Solution Sites Provides a brief explanation of the string concatenation methodology used within the Solution Sites script to build strings containing complex HTML.
- Categories of Routines used for Solution Sites Provides a functional categorization of the routines in the file include\html_lib.asp.
Copyright © 2005 Microsoft Corporation.
All rights reserved.