Creating Master.page File

The first step of converting HTML code into Sitebuilder template source code is creating the Master.page file in the root directory of the created template. The Master.page file contains code of a site page. This file is used with all color schemes (it must not contain information related only to a particular color scheme).

File Master.page must be comprised of HTML code, Sitebuilder controls and variables. HTML code is used to create a site layout. Controls and variables are used to fill the site with dynamic content. The standard site layout defined in the Master.page file can be schematically represented in the following way:

To create the Master.page file, create a new text document in the template root directory and paste the HTML code generated from a template design into it. Then perform the following actions on the text document:

  1. Find HTML code of the top-level menu and replace it with the <Sitebuilder:Container ID="TopMenu"/> control.
  2. Find HTML code of the lower-level menu and replace it with the <Sitebuilder:Container ID="SubMenu"/> control.
  3. Find HTML code of the content area and replace it with the <Sitebuilder:Container ID="Content"/> control.
  4. (Optional) Find HTML code of the bottom-level menu and replace it with the <Sitebuilder:Container ID="BottomMenu"/> control.

    Note: If the design did not have the bottom-level menu, you can omit the step.

  5. Find HTML code of the page title and replace it with the $PageTitle$ variable.
  6. (Optional) Find URL to the site logo image and replace it with the $LogoPath$ variable. If you are not using the logo image on the site, insert the element <img src="$LogoPath$" /> into any place of the file, and put the transparent 1 x 1 pixel file called logo.gif into the Images directory.
  7. Save the text document as Master.page

Note: All controls and variables added to master.page at steps 1,2,3,4,7 are required.

Variable $HomePageUrl$ stores URL to a site home page. Optionally, you can substitute the path to a site home page with the variable.

For details on how to create custom menus style, refer to the Creating Menu Style section.

Sometimes end-users want to customize the site title, subtitle and copyright information. To give the users an opportunity to customize additional site elements, open the Master.page in the text editor and do the following:

Note: These steps are optional, so you can omit them.