Microsoft Solution for Internet Business

Architecture Guide

Published: October 1, 2002
On This Page
AbstractAbstract
IntroductionIntroduction
Solution DesignSolution Design
Solution TechnologiesSolution Technologies
Solution ArchitectureSolution Architecture

Abstract

This guide describes the architecture of Microsoft Solution for Internet Business (MSIB), and focuses on the software architecture of the templated Web site provided with MSIB. It also describes the various technologies that contribute to the solution.

Introduction

Microsoft Solution for Internet Business (MSIB) integrates a number of different Microsoft products into a solution that enables the development of comprehensive Web sites for Internet presence and electronic commerce. These products include:

Microsoft® Windows® 2000 Advanced Server

Microsoft® Content Management Server (MCMS) 2002

Microsoft® Commerce Server 2002

Microsoft® SQL Server™ 2000

Microsoft® Internet Security and Acceleration (ISA) Server 2000

MCMS and Commerce Server are the primary, front-line server products used in the solution. SQL Server provides the underlying database services for both MCMS and Commerce Server. When deploying an MSIB solution, ISA Server can be used to achieve the required management, security functionality, and caching for your site. Microsoft® SharePoint™ Portal Sever can be used to provide a site search feature.

The Web site provided with MSIB is intended to provide a common starting point for corporate Web sites. Exact Web site requirements and design preferences will vary from company to company, and so it is expected that experienced consultants will begin with the MSIB Web site and create a customized solution for their client.

This document consists of three sections that describe the solution design. The first describes the design of an MSIB solution from the perspective of the three-phase design approach used by the Microsoft Solutions Framework (MSF):

Conceptual design

Logical design

Physical design

The second section describes the roles of the various Windows Server System™ products that are used in an MSIB solution.

The third section describes the architecture of an MSIB solution; how all of the constituent products are integrated to achieve the solution.

Reader Guidance

This guide assumes a strong understanding of both MCMS and Commerce Server, and to a lesser extent, the other enterprise server products used in this solution. Refer to the relevant product documentation to gain the required level of familiarity. Additionally, the MSIB Developer's Guide provides information about developing a solution based on MSIB, and provides network, software, and hardware configuration details, including network diagrams, hardware specifications, and step-by-step software configuration instructions.

Solution Design

An MSIB Web site presents information to users in a way that achieves the business objectives for the company. Companies want to target content to users based on their business initiatives and on the preferences of their customers. The solution design of MSIB consists of brief descriptions of the sequence of conceptual, logical, and physical designs that resulted in MSIB.

Conceptual Design

The conceptual design of an MSIB solution can be expressed as a statement of the basic functional requirements of each functional area in the MSIB templated site. The templated site has been provided so the developer can use it as a starting point to develop more complex Web sites. The templated site has the minimum amount of content while providing the rich infrastructure to support the need to easily and quickly add content to the site. The following table provides such statements.

Functional areaBasic functional requirements

User Profiles

The capacity for identifying a particular user (authentication), and for storing information about that user (profiling).

Further, the type of information stored for users must be easily configurable. For example, it should be easy to add new user properties, such as age ranges, income ranges, and so on.

Personalization

The capacity for presenting customized content to a user based on one or more of the following:

User profile

Content attributes

Contextual information, such as the type of the page or the position of targeted content in a page

Customized content may come from a Commerce Server catalog or from MCMS.

Content Production and Presentation

An easy and intuitive way for non-technical personnel to produce new content for the Web site, and for that content to be presented to the users of the Web site.

Content Workflow

A mechanism for new Web site content to participate in workflow (such as content approval by someone other than the content author) prior to appearing on the Web site.

Navigation and Search

An easy and intuitive way for users to find the pages or items of interest on the Web site.

Product Presentation

Mechanisms for displaying the relevant information about the products for sale on the Web site.

Logical Design

The logical design of an MSIB solution can be expressed as a statement of the logical components required to implement the functional areas of the MSIB templated site. The following table provides such statements. These logical components may not reside within the physical components.

Functional areaCorresponding logical components

User Profiles

User Profile Store. This logical component is where the user profile data is maintained. It supports data population, retrieval, and modification.

Web Site Interface. This logical component is the interface through which users provide, view, and maintain their own profile information.

Management Interface. This logical component is the interface through which operators view and modify user profiles.

User Profile Data Generation Processing. Logical components in this category are automated processes that update user profiles as part of their processing. For example, a bulk mailing process that records the type and date of the mailings sent to a user.

Content Production and Presentation

Web Site Content Store. This logical component is where the Web site content, once created, is stored, and from which it is retrieved for display on the Web site.

Content Creation Interface(s). This logical component is the interface(s) used to produce the Web site content.

Content Presentation Interface(s). This logical component is the interface(s) used to create the structure of the Web site, both between pages and within a given page.

Content Assembly Process. This logical component is the process through which the Web site content, constructed in separate pieces, is assembled and displayed to the user.

Product Presentation

Product Data Source. This logical component is the origin of the product data. It supports data population, retrieval, and modification.

Product Data Store. This logical component is the location in which the product data is stored and updated.

Web Site Product Pages. This logical component is the set of pages on the Web site that are used to display product information.

Management Interface. This logical component is the interface used to maintain product data.

Personalization

Data Upon Which the Personalization is Based. This logical component consists of the rules engine and the rule expressions that are used to assemble data that is specific to a given user, and upon which the presentation of personalized content will be based.

Records of Past Personalization. This logical component is the record maintained, if any, of the content that has already been displayed. This can be used to prevent the same personalized content from being repeatedly displayed.

Web Site Interface. This logical component is the interface through which users are presented with personalized content. In other words, pages on the Web site that are designed to display personalized content.

Management Interface. This logical component is the interface through which content designers and business managers configure the display of personalized content.

Personalization Processing. This logical component is the processing used to determine which personalized content to display for a particular user.

Content Workflow

Workflow Records. This logical component constitutes the records maintained to track the workflow state of various items of content.

Workflow Interface(s). This logical component is the interface(s) through which different content contributors perform their tasks related to the proposed content, and through which the content is eventually either approved or rejected.

Navigation and Search

Navigation Features on Web Site Pages. This logical component is the set of navigation mechanisms provided on the Web site pages, enabling users to move between the different pages on the site.

Search Features on the Web Site Pages. This logical component is the set of search mechanisms provided on the Web site pages, enabling users to search for products and other types of content.

Search Preparation Processing. This logical component is the offline processing that occurs to prepare a Web site for being searched. For example, the indexing of the Web site pages.

Run Time Search Processing. This logical component is the processing that occurs when a search operation is initiated.

Search Results Display. This logical component is the mechanism used to display the search results to the user.

Physical Design

The physical design of an MSIB solution can be expressed as a statement of the physical components required to implement the logical components of the design, as described in the previous section. The following table provides such statements.

Functional areaCorresponding physical components

User Profiles

Commerce Server Profiling System. This physical component provides the infrastructure for maintaining user and page profiles in MSIB. This includes the Profiles resource, managed through Commerce Server Manager and the Users modules, managed through Commerce Server Business Desk. Profile data is stored in the Profiles data store in SQL Server.

Web Site Pages. This physical component consists of the Web site pages provided with MSIB that enable users to view and modify their profile information. These pages include the new user page, the modify profile page, the About Us page, Careers page, FAQ page, Privacy Policy page, Investor Relations page, and the Contact Us page.

SQL Server. This physical component is used to provide the underlying storage for the user profile data.

Personalization

Commerce Server Targeting System. This physical component provides the infrastructure for personalizing Web content for users of an MSIB solution. This includes:

Campaigns modules. Business Desk modules used to manage targeting and personalization in Commerce Server.

Expression Builder. An intuitive user interface that business managers use to create expressions that target content to any business item that has a profile.

Direct Mailer. A fast, scalable Windows 2000 service that you use to send personalized e-mail messages from a Web page, or non-personalized mailings from a flat text file, to large groups of recipients. It uses lists from the List Manager.

Content Connector for Commerce Server 2002. This involves multiple components that are server controls, Business Desk modules, and Web pages. The two primary features are content targeting and product catalog editing. Content Connector integrates Commerce Server and MCMS functionality and workflows to enable product editing through the site. Content Connector runs a PCO pipeline to select content based on the user profile, the page profile, and/or campaign information. The page profile is a set of properties defined for a page within MCMS. MCMS defines Personalized Content Objects (PCOs), which can be used to provide links to related content and product information. These objects can be managed from the customized MSIB Business Desk Targeting and Content modules.

Web Site Pages. This physical component consists of the Web site pages that are designed to show personalized content using the Commerce Server Targeting System and Targeting Content Control.

SQL Server. This physical component is used to provide the underlying storage for the targeting data.

Content Production and Presentation

Content Management Server. This physical component provides the primary infrastructure for managing content in an MSIB solution. All of the Web site pages are constructed using MCMS page templates and published through MCMS channels and postings. Authentication and privilege checking is performed using built in MCMS mechanisms.

Web site pages. This physical component provides a variety of .aspx pages and classes in the code-behind pages that are used to generate certain types of content, particularly content that is generated using calls to Commerce Server objects. These pages represent MCMS templates and contain server controls and Windows Server System-based components, with functionality provided by the MSIB framework DLLs.

Content Workflow

Content Management Server. This physical component provides the primary infrastructure for managing content workflow processing in an MSIB solution. MCMS can be configured such that content workflow is enforced as part of the content creation process. Workflow is based on user roles, such as authors and editors.

SQL Server. This physical component is used to provide the underlying storage for the MCMS workflow processing.

Navigation and Search

Web site page navigation infrastructure. This physical component consists of the page navigation infrastructure. Site pages use the framework class UrlBuilder to construct links and to redirect to other pages. The UrlBuilder class methods ensure that any cookie information is carried over in the URL when cookies are disabled.

HTML Web site search. This physical component is HTML Web site crawling provided by third party products.

Commerce Server catalog search. This physical component consists of the search capabilities of the Commerce Server Catalog System and the search framework components provided by MSIB.

Search interface on the Web pages. These physical components are the search and advanced search user controls found on various pages on the Web site.

Product Presentation

Commerce Server Product Catalog System. This physical component provides the primary infrastructure for managing product data in an MSIB solution. This includes the Commerce Server Business Desk modules in the Catalogs category, as well as the various COM objects that are used to retrieve catalog data for display on Web site pages and support catalog search functionality.

Catalog data source. This physical component consists of the original source of the catalog data. The source might be an XML or comma-separated values (CSV) file that is imported into the Commerce Server Catalog System.

Web site pages. This physical component consists of the Web site pages that are designed for displaying product information.

SQL Server. This physical component is used to provide the underlying storage for the Product Catalog System.

Solution Technologies

MSIB relies on certain technologies about which you must be (or become) familiar. These include several existing Windows Server System products.

Developers working with MSIB must be familiar with Web user interface technologies such as HTML, ASP.NET, Microsoft® Visual Basic Scripting Edition (VBScript), Internet Explorer, Microsoft Visual C#, DHTML, XML data islands, and so on. Familiarity with COM, including using COM objects from Visual Basic is also recommended.

The following table briefly reviews the main technologies used by MSIB, including the roles of MCMS, Commerce Server, SQL Server, and ISA Server.

Windows Server System productRole in MSIB

MCMS

MCMS 2002 is the presentation server for MSIB. In other words, the MSIB site, around which an entire MSIB solution is structured, is an MCMS-managed Web site. The pages are defined in MCMS folders, based on templates defined in the MCMS templates gallery, and posted to MCMS channels. The Content Connector for Commerce Server 2002 is also used to achieve certain aspects of the integration with Commerce Server 2002.

Commerce Server

MSIB makes use of the Commerce Server Profiling System, the Commerce Server Targeting System, and the Commerce Server Product Catalog System.

The Content Connector for Commerce Server 2002 integrates with Commerce Server, including the addition of several new modules to the Commerce Server Business Desk that are used to target content managed within MCMS at site users based on campaigns and user profiles.

SQL Server

SQL Server 2000 provides the underlying database services for MCMS and Commerce Server and is, therefore, a fundamental underlying part of an MSIB solution.

ISA Server

Microsoft Internet Security and Acceleration (ISA) Server 2000 is an extensible enterprise firewall and Web cache server that provides powerful security and network acceleration. It is used in an MSIB solution to provide the firewalls that are required for security purposes in deployment environments.

Solution Architecture

This section provides a description of the architecture of an MSIB solution. The architecture is first described from a high level that shows how the various servers might be deployed, including their relative positions within the intranet, the perimeter network (also known as DMZ, demilitarized zone, and screened subnet), and the Internet zones. The architecture is then described from a lower level that describes how the primary servers in the solution (MCMS, Commerce Server, and SQL Server) are used together to implement the templated site. You may also want to read relevant portions of the MSIB Developer's Guide for more detailed information about customizing the templated site, and the MSIB Developer Deployment Guide for more information about MSIB network, software, and hardware configuration details.

MSIB Software Architecture

MCMS and Commerce Server are the primary high-level servers used in an MSIB solution. SQL Server is used extensively by both of these servers, and is therefore, primary to an MSIB solution as well. Depending on your deployment scenario, ISA Server and Application Center can also be used in an MSIB solution. Finally, some MSIB solution scenarios may call for the inclusion of SharePoint Portal Server.

A primary aspect of MSIB is the templated site that is included with the solution. The following figure shows the software architecture of this site.

In the figure, the arrows are labeled as follows:

Reference – The corresponding arrow is labeled as reference because the MCMS page templates reference the template .aspx files. You use the MCMS Template Explorer to make associations between MCMS page templates and the template .aspx files.

Inherits from – Each template .aspx file inherits functionality from a class defined in the associated code-behind page. The code-behind page handles object instantiation, events, and interaction with Commerce Server and MCMS objects.

Instantiate and Invoke – The code-behind page contains derived classes that instantiate Commerce Server Base Class Library (BCL) objects and MCMS objects to perform a variety of tasks.

Commerce Server is used to provide a variety of dynamic content for pages in the MSIB templated site, including:

Personalized content generated by the Commerce Server Targeting System (using the MSIB Personalized Content Object pipeline, expressions, user profile information, and so on).

User profile information retrieved from the Commerce Server Profiling System.

Product information content retrieved from the Commerce Server Catalog System.

MSIB Web sites can be extended to use the predictive and segmentation models available in Commerce Server.

The various aspects of the MSIB software architecture, as shown in the figure above, are discussed in the following section.

MCMS Page Architecture

The GenericTemplate.aspx template is intended to be used as a starting point for your own templates. It provides basic formatting and demonstrates how to use user controls. You can extend this template and use it when developing your own Web site. Some templated pages included in the MSIB templated site, such as the Corporate Information sample page, were based on the GenericTemplate.aspx file.

The content area on the page is implemented in one of two ways. First, if the page does not need to invoke Commerce Server objects to retrieve its content, the page can be managed completely from within MCMS, with one or more placeholder controls in the template reserving space for the customized content for the page. For example, a page that provides a job description would not normally need to interact with Commerce Server. In MCMS, such pages are known as having "rich content", in that they contain placeholders that can support a variety of content types including images and formatted text.

The second way in which the content area of pages is implemented is for those pages that do need to invoke Commerce Server objects to retrieve their content. The content area of such pages is implemented as the inclusion of a combination of MSIB-specific placeholder controls (ProductPropertyPlaceholderControl) and MCMS intrinsic placeholder controls. Ultimately, most of the content that is displayed on the pages in the MSIB templated site is stored in SQL Server, either in the form of "rich content" managed by MCMS, or in the form of the data stored within the various Commerce Server databases.

Visual Page Layout

This section shows the visual layout of a typical page in the MSIB templated site, and shows how the page is functionally divided into distinct areas. The table after the following figure explains the purpose of each area, and the next section, "Page Layout Code", shows how the underlying code in the templated site produces this layout.

The following table describes the purpose of each content area identified in the figure above.

Labeled Page AreaDescription

1 – Page Header

This area provides the title for the page.

2 – Top Navigation Bar

This area is used for overall site navigation and includes items such as Home, Basket, FAQs, Contact Us, Press, Search, Help, About, and so on. Logically, this is a distinct area, but physically it is implemented by the same Header server control.

3 – Left Navigation Bar

This area is the left navigation area and is used for login, search, a catalogs list, and links to other pages that display user-specific information such as the user profile, address book, and orders.

4 – Main Content Area

This area contains the main content of the page, and is thus completely dependant on the page implementation.

On some pages, this area is controlled by an MCMS placeholder in the underlying template, such that the associated rich content can participate in the MCMS workflow.

On other pages, the content for this area is retrieved from Commerce Server using a ProductPropertyPlaceholderControl included in the underlying MCMS page template.

5 - Footer

This area is used to close off the look and feel of the page and typically contains copyright information.

GenericTemplate.aspx Page

This section shows the GenericTemplate.aspx page and divides it into a number of sections that are then explained in a table that follows the code.

SectionCode

1.

<%@ Register TagPrefix="ebiz" TagName="SearchControl"
Src="../UserControls/SearchControl.ascx" %>

<%@ Register TagPrefix="CMS"
Namespace="Microsoft.ContentManagement.WebControls"
Assembly="Microsoft.ContentManagement.WebControls" %>
<%@ Register TagPrefix="eBiz" TagName="PageHeader"
Src="../UserControls/Header.ascx" %>
<%@ Register TagPrefix="eBiz" TagName="PageFooter"
Src="../UserControls/Footer.ascx" %>
<%@ Register TagPrefix="eBiz" TagName="DefaultConsole" Src="../UserControls/DefaultConsole.ascx" %>
<%@ Register TagPrefix="ebiz" TagName="SearchControl" Src="../UserControls/SearchControl.ascx" %>
<%@ Register TagPrefix="CMS" Namespace="Microsoft.ContentManagement.WebControls"
Assembly="Microsoft.ContentManagement.WebControls"
%>
<%@ Register TagPrefix="eBiz" TagName="PageHeader"
Src="../UserControls/Header.ascx" %>
<%@ Register TagPrefix="eBiz" TagName="PageFooter"
Src="../UserControls/Footer.ascx" %>
<%@ Register TagPrefix="eBiz" TagName="DefaultConsole"
Src="../UserControls/DefaultConsole.ascx" %>

2.

<%@ Page language="c#" Codebehind="GenericTemplate.aspx.cs"
AutoEventWireup="false"
Inherits="ContentConnector.Templates.GenericTemplate" %>

3.

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN" >
 
 <HTML>
    <HEAD>
        <title>
            Microsoft Content Connector - Generic Template Page
            </title>
            <meta content="Microsoft Visual Studio 7.0"
                 name="GENERATOR">
            <meta content="C#" name="CODE_LANGUAGE">
            <meta content="JavaScript" name="vs_defaultClientScript">
            <meta
                content="http://schemas.microsoft.com/intellisense/ie5"
                   name="vs_targetSchema">
            <LINK href="<%= "/" + CommerceContext.Current.SiteName+
                   "/Styles.css" %>" type="text/css" rel="stylesheet">
            <base href="<%= Page.Request.Url.AbsoluteUri%>">
     </HEAD>
       <BODY MS_POSITIONING="GridLayout">
          <form id="genericTemplate" method="post" runat="server">

4.

<!-- PageHeader Starts -->

       <eBiz:PageHeader id="pageHeader" runat="server" />
<!-- PageHeader Ends -->

5.

<!-- Main Content Starts -->

<asp:Table ID="mainContent" Height="100%" Width="100%"
     CellSpacing="0" CellPadding="0" BorderWidth="0"
     CssClass="clientArea" Runat="server">
     <asp:TableRow height="100%" VerticalAlign="top"
               Runat="server">
               <asp:TableCell height="100%" VerticalAlign="top"
                          HorizontalAlign="left" Width="250px" runat="server">
                          <asp:Table id="menuTable" CssClass="menuStyle"
                                    CellSpacing="0" CellPadding="0" runat="server">

6.

<asp:TableRow Height="100%" Width="100%" runat="server">
    
    <asp:TableCell CssClass="menuTopCellStyle" runat="server">
       <ebiz:SearchControl id="searchControl" runat="server" />
    </asp:TableCell>
</asp:TableRow>

7.

<asp:TableRow runat="server">
    
    <asp:TableCell CssClass="menuCellStyle" style="vertical-
        align:top" Runat="server">
       <eBiz:DefaultConsole id="defaultConsole" runat="server" />
    </asp:TableCell>
</asp:TableRow>

8.

 <asp:TableRow Runat="server">
     
     <asp:TableCell Height="15px" CssClass="menuBottomCellStyle"
         runat="server"></asp:TableCell>
     </asp:TableRow>
   </asp:Table>
</asp:TableCell>

9.

<asp:TableCell ID="htmlPlaceholderCell"
 
 
   CssClass="htmlPlaceholderCell" VerticalAlign="Top"
   Runat="server">
   <CMS:HtmlPlaceholderControl id="htmlPlaceholder" runat="server"
       EditControlWidth="530"
       placeholdertobind="htmlPlaceholderDefinition" />
</asp:TableCell>
</asp:TableRow>
</asp:Table>
<!-- Main Content Ends -->

10.

<!-- PageFooter Starts -->

<eBiz:PageFooter id="pageFooter" runat="server" />
<!-- PageFooter Ends -->

11.

         </form>
     </body>
</HTML>

The following table explains the different code sections identified above in the GenericTemplate.aspx page.

SectionDescription

1

Registration information for various MSIB user controls. These include Header, Footer, SearchControl, and DefaultConsole, together with registration of the MCMS Web controls namespace.

These controls create objects and perform various setup/rendering tasks needed for most pages.

2

Page directive used to associate the page with the corresponding code-behind page and class, and to set various parameters (language, AutoEventWireup, and so on).

3

Meta data about the page and references to the associated stylesheets used by the page.

The opening of the page content division. The entire body of the page is encapsulated inside this form tag.

4

Header user control inserted in the page using the tagprefix and tagname attributes defined in the corresponding Register directive.

5

Main page content is structured and rendered using a certain number of table Web controls where mainContent and menuTable are the most representative controls. Specific styles and rendering attributes (height/width) are set at Table, TableRow and TableCell levels.

6

Search user control inserted in the .aspx page.

7

DefaultConsole user control inserted in the .aspx page.

8

TableCell element used for formatting/rendering purposes only (to add the bottom style of the menuTable).

9

MCMS intrinsic HtmlPlaceholderControl used for adding/editing/rendering generic content under full MCMS control.

10

Footer user control inserted in the page using the tagprefix and tagname attributes defined in the corresponding Register directive.

11

HTML content that ends the Form, BODY, and HTML elements in the .aspx page.

GenericTemplate.aspx.cs Page

This section shows the GenericTemplate.aspx.cs code-behind page upon which the GenericTemplate.aspx file depends for its functionality. This section divides the file into a number of sections that are then explained in a table that follows the code.

SectionCode

1.

#region Namespaces


using System;


using System.Collections;


using System.ComponentModel;


using System.Data;


using System.Drawing;


using System.Web;


using System.Web.SessionState;


using System.Web.UI;


using System.Web.UI.WebControls;


using System.Web.UI.HtmlControls;


#endregion

2.

namespace ContentConnector.Templates

{

           /// <summary>


          /// Summary description for GenericTemplate.


           /// </summary>


           public class GenericTemplate : System.Web.UI.Page


           {


           #region Data Members


//


// Protected


//


protected System.Web.UI.WebControls.Table mainContent; 


#endregion

3.

 #region Methods


            private void Page_Load(object sender, System.EventArgs e)


                {


                // Put user code to initialize the page here


                 }

4.

              override protected void OnInit(EventArgs e)


              {


              //


             // CODEGEN: This call is required by the ASP.NET Web 


// Form Designer.


             //


InitializeComponent();


             base.OnInit(e);


           }


//


           /// <summary>


          /// Required method for Designer support - do not modify


          /// the contents of this method with the code editor.


          /// </summary>


//


         private void InitializeComponent ()


         { 


         this.Load += new System.EventHandler(this.Page_Load);


         }


     #endregion


     }

}

The following table explains the different code sections identified in the above GenericTemplate.aspx.cs code-behind page.

SectionDescription

1

Code region used to declare all Namespaces used in this file.

2

Region used for class and associated namespace definition plus declaration of all instance or class (static) Data Members.

3

Starts the Methods region with the private Page_Load method. This is where you perform various types of initialization on your .aspx page, such as loading the localizable resource values.

4

Also part of the Methods region, this area includes the OnInit event handler and the InitializeComponent private method automatically added through Visual Studio .NET. Depending on your exact needs, you can keep this design pattern, or remove the InitializeComponent method and move the setting of the Page_Load event handler to the OnInit event handler.

RichProductTemplate.aspx Page

This section shows the RichProductTemplate.aspx page and divides it into a number of sections that are then explained in the table that follows the code.

SectionCode

1.

<%@ Register TagPrefix="CMS"
Namespace="Microsoft.ContentManagement.WebControls"
Assembly="Microsoft.ContentManagement.WebControls" %>
<%@ Register TagPrefix="ebiz"
Namespace="Microsoft.Solutions.Framework"
Assembly="Microsoft.Solutions.ContentConnector, Version=2.0.146.0,
Culture=neutral, PublicKeyToken=fa6ab6564e139293" %>
<%@ Register TagPrefix="uc1" TagName="DefaultConsole"
Src="../UserControls/DefaultConsole.ascx" %>
<%@ Register TagPrefix="ebiz" TagName="PageHeader"
Src="../UserControls/Header.ascx" %>
<%@ Register TagPrefix="ebiz" TagName="PageFooter"
Src="../UserControls/Footer.ascx" %>
<%@ Register TagPrefix="ebiz" TagName="SearchControl"
Src="../UserControls/SearchControl.ascx" %>

2.

<%@ Page language="c#" Codebehind="RichProductTemplate.aspx.cs"
AutoEventWireup="false"
Inherits="Microsoft.Solutions.Applications.RichProductTemplatePage" %>

3.

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN" >

<HTML>
        <HEAD>
                <title>
                      Microsoft Content Connector Product Template Page
                </title>
               <meta name="GENERATOR" Content="Microsoft Visual Studio
                         7.0">
               <meta name="CODE_LANGUAGE" Content="C#">
               <meta name="vs_defaultClientScript" content="JavaScript">
               <meta name="vs_targetSchema"
                      content="http://schemas.microsoft.com/intellisense/ie5">
               <LINK href="<%= "/" + CommerceContext.Current.SiteName+
                         "/Styles.css" %>" type="text/css" rel="stylesheet">
               <base href="<%= Page.Request.Url.AbsoluteUri%>">
         </HEAD>
         <body MS_POSITIONING="GridLayout">
	       <form id="ProductTemplate" method="post" runat="server">

4.

<!-- PageHeader Starts -->

         <ebiz:PageHeader runat="server" id="pageHeader" />
<!-- PageHeader Ends -->

5.

<asp:Table height=67% width=100% CssClass="clientArea" CellSpacing=0

                      CellPadding=0 BorderWidth=0 runat="server">
          <asp:TableRow runat="server">
                    <asp:TableCell Width=250px VerticalAlign="Top" runat="server">
                               <asp:Table id="menuTable" CssClass="menuStyle"
                                             CellSpacing=0 CellPadding=0 runat="server">

6.

<asp:TableRow runat="server">

           <asp:TableCell CssClass="menuTopCellStyle" runat="server">
                       <ebiz:SearchControl id="searchControl" runat="server" />
          </asp:TableCell>
</asp:TableRow>

7.

<asp:TableRow runat="server">

          <asp:TableCell CssClass="menuCellStyle" runat="server">
                    <uc1:DefaultConsole id="defaultConsole" runat="server" />
          </asp:TableCell>
</asp:TableRow>

8.

                     <asp:TableRow Runat="server">
 
                               <asp:TableCell Height="15px"
                                         CssClass="menuBottomCellStyle" runat="server">
                              </asp:TableCell>
                     </asp:TableRow>
          </asp:Table>
</asp:TableCell>

9.

<asp:TableCell VerticalAlign="top" HorizontalAlign="left"

        runat="server">
        <br>
	<p>
	         <asp:Panel Font-Bold="True" Runat="server">
			  <asp:Literal ID="productName" Runat="server" />
		 </asp:Panel>
	 </p>
	 <p>
		 <ebiz:ProductPropertyPlaceholderControl
		 	    id="namePlaceholderControl" PropertyName="Name"
			    placeholdertobind="ProductPropertyDataSetPlaceholder"
			    runat="server" />
	 </p>
	 <p>
		 <asp:Panel Font-Bold="True" Runat="server">
			   <asp:Literal ID="productDescription" Runat="server" />
		 </asp:Panel>
	 </p>
	 <p>
		 <ebiz:ProductPropertyPlaceholderControl
			   id="descriptionPlaceholderControl"
			   PropertyName="Description"
			   placeholdertobind="ProductPropertyDataSetPlaceholder"
		  	   runat="server" />
	 </p>
	 <p>
		 <asp:Panel Font-Bold="True" Runat="server">
			   <asp:Literal ID="productPrice" Runat="server" / >
		 </asp:Panel>
	 </p>
	 <p>
		 <ebiz:ProductPropertyPlaceholderControl
			    id="pricePlaceholderControl"
			    PropertyName="cy_list_price"
			    placeholdertobind="ProductPropertyDataSetPlaceholder"
			    runat="server" />
	 </p>
	 <p>
		 <asp:Panel Font-Bold="True" Runat="server">
  		 	    <asp:Literal ID="productCopy" Runat="server" />
		 </asp:Panel>
	 </p>
	 <p>
		 <cms:HtmlPlaceholderControl
			    id="productCopyPlaceholderControl"
			    placeholdertobind="ProductCopyPlaceholder"
			    runat="server" />
	 </p>
	 <br>
		 </asp:TableCell>
	 </asp:TableRow>
</asp:Table>

10.

<!-- Page Footer Starts -->

             <ebiz:PageFooter id="pageFooter" runat="server" />
<!-- Page Footer Ends -->

11.

                    </form>
 
           </body>
</HTML>

The following table explains the different code sections identified in the above RichProductTemplate.aspx page.

SectionDescription

1

Registration for various MSIB user controls. These include Header, Footer, SearchControl, and DefaultConsole, together with registration of the MCMS Web controls namespace.

These controls create objects and perform various setup/rendering tasks needed for most pages.

2

Page directive used to associate the page with the corresponding code-behind page and class, and to set various parameters (language, AutoEventWireup, and so on).

3

Meta data about the page and references to the associated stylesheets used by the page.

The opening of the page content division. The entire body of the page is encapsulated inside this form tag.

4

Header user control inserted in the page using the tagprefix and tagname attributes defined in the corresponding Register directive.

5

Main page content is structured and rendered using a certain number of table Web controls where mainContent and menuTable are the most representative controls. Specific styles and rendering attributes (height/width) are set at Table, TableRow, and TableCell levels.

6

Search user control inserted in the .aspx page.

7

DefaultConsole user control inserted in the .aspx page.

8

TableCell element used for formatting/rendering purposes only (to add the bottom style of the menuTable).

9

Content emphasizing the usage of MSIB custom ProductPropertyPlaceholderControls for editing/rendering Commerce Server catalog-specific properties, such as product Name, Description, and ListPrice.

For data binding purposes, the actual catalog property names are used. For all the catalog properties exposed through this content connectivity feature (product catalog editing), you bind the ProductPropertyPlaceholderControls to another custom placeholder ProductPropertyDataSetPlaceholder.

10

Footer user control inserted in the page using the tagprefix and tagname attributes defined in the corresponding Register directive.

11

HTML content that ends the Form, BODY, and HTML elements in the .aspx page.

RichProductTemplate.aspx.cs Page

This section shows the RichProductTemplate.aspx.cs code-behind page upon which the RichProductTemplate.aspx file depends for its functionality. The code is divided into a number of sections that are then explained in the table following the code.

SectionCode

1.

#region Namespaces

using System;
using System.Collections;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Web;
using System.Web.SessionState;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Web.UI.HtmlControls;

using Microsoft.Solutions.Framework;
using Microsoft.ContentManagement.Publishing;
using Microsoft.ContentManagement.Publishing.Extensions.Placeholders;
using Microsoft.ContentManagement.WebControls;
using Microsoft.CommerceServer.Runtime.Catalog;
using Microsoft.Web.UI.WebControls;

#endregion

2.

namespace Microsoft.Solutions.Applications
{
     public class RichProductTemplatePage : System.Web.UI.Page
     {
 	#region Data Members
 	//
	// Protected
	//

	protected Literal productName;
 	protected Literal productDescription;
 	protected Literal productPrice;
 	protected Literal productCopy;

 	//
 	// private static
	//
 
 	private static readonly string currencyString = "currency";

 	#endregion

3.

   #region Methods
 //================================================================
 // 	Event: Init
 //
 // 	Description:
 /// <summary>
 /// 	Init handler.
 /// </summary>
 //
 //================================================================
 override protected void OnInit(EventArgs e)
 {
     this.Load += new System.EventHandler(this.Page_Load);
     base.OnInit(e);
 }
 

4.

  //===============================================================
 //   	 Event: Page_Load
 //
 // 	  Description:
 /// <summary>
 /// 	Page_Load handler.
 /// </summary>
 //
 //===============================================================
 private void Page_Load(object sender, System.EventArgs e)
 {
  //
 // Set localizable resources
 //
 productName.Text = ResourceStrings.GetString
 			(ResourceStrings.ProductNameText);
 productDescription.Text = ResourceStrings.GetString
			(ResourceStrings.ProductDescriptionText);
 productPrice.Text = ResourceStrings.GetString
 			(ResourceStrings.ProductPriceText);
 productCopy.Text = ResourceStrings.GetString
			(ResourceStrings.ProductCopyText);
 //
 // Set the currency symbol to the currency of the catalog
 // that we are within.
 //
 //

 ContentConnectorContext contentConnectorContext;

 contentConnectorContext = ContentConnectorContext.Current;

 ProductPosting productPosting =
		    contentConnectorContext.ProductPosting;
 if (productPosting != null)
 {
	 string currencyCode = (string)
			 productPosting.Product.ProductCatalog.
			 GetCatalogAttributes().Tables[0].Rows[0]
			 [RichProductTemplatePage.currencyString];
	 System.Threading.Thread.CurrentThread.
	 CurrentCulture.NumberFormat.CurrencySymbol =
		 (string) MicrosoftInternetBusinessSite.
			  CurrencySymbols [currencyCode];
 }
 else
 {
 	UrlBuilder.Redirect ("default.aspx");
 }
 #endregion
 }
}

The following table explains the different code sections identified in the RichProductTemplate.aspx.cs code-behind page.

SectionDescription

1

Code region used to declare all Namespaces used in this file.

2

Region used for class and associated namespace definition plus declaration of all instance or class (static) Data Members.

3

Starts Methods region with the protected OnInit event handler. This is where you set the Page_Load event handler.

4

Also part of the Methods region, this area includes the Page_Load event handler used for various types of initialization, such as setting the localizable resource values for several Literal controls on a page, setting the currency symbol for the current thread based on product catalog information associated with the current MCMS page.

Scalability, Availability, and Security

MSIB includes a number of options that support your need for scalability, availability, and security. These options include the following:

Scalability. Microsoft developer tools and Windows Server System products have the advantage of being highly scalable. Deployment may be scaled horizontally at the Web and database tier by adding Web or database servers. It may also be scaled vertically to data center class hardware in the database tier. This enables your business to start small and then scale to a larger, enterprise-level design.

Availability. The Windows Server System is designed to take advantage of cluster services, network load balancing, and hardware solutions to remove the single points of failure in a deployment.

Security. Microsoft has a strong solution for firewall, security accounts, security management, and security logging across a breadth of products. The deployment scenarios described in the MSIB Developer Deployment Guide use these features to create a highly secure environment for deployment.


**
**