To compile a template, you must create a file where basic technical information about a template is stored. The file is named
info.xml. It should be located in the template root directory.
The structure of the
info.xml file is as follows:
<?xml version="1.0" encoding="UTF-8"?>
<template id="yourCompany-business-001" version="1.0" caption="Business site" formatVersion="4" keywords=" business books" category="Business" >
<theme id="Green" caption="Green scheme"/>
<theme id="Yellow" caption="Yellow scheme"/>
<theme id="Orange" caption="Orange scheme"/>
<browser>MS IE 6.0</browser>
<browser>Mozilla FireFox 1.5</browser>
The first line, called XML declaration, defines the version of XML and the charset used in the document.
The root element of the document is
template. It has the following attributes:
. This attribute contains the name of the template. The name of the template should start with the name of your company, so that the template would be easily identified in Sitebuilder. The template name should coincide with the name of the directory containing the template content. If the template pack will be used in Sitebuilder for Linux/Unix, then the templates' names should contain only Latin characters, numerical digits, underscores ( _ ), dots, and dashes.
version. This attribute contains the template version.
Version number consists of 2 digits:
This attribute contains the description of the template. This can be any text of your choice, for example, "Travel company".
(Optional) This attribute contains the version of SDK that is used to compile the template . If you create the template using Sitebuilder SDK v. 4.0, then put "4" into this section. If you use SDK v. 3.2, then there is no need to include the
formatVersionsection in the
info.xmlfile, because the format's version will be automatically defined as "3" during template compilation.
keywords.This attribute contains the list of keywords that a user might enter to find the template at the Design step of the Wizard. Therefore, provide keywords which best describe you template.
category.This attribute specifies the category the template belongs to, for example, "Business". It may contain a blank value or be absent.
template element has the following child elements:
The element contains information about colour schemes used in the template. Its attributes are as follows:
. (Optional) It defines default color scheme.
. (Optional) Defines if the custom header banner can be uploaded in Sitebuilder Wizard. For details, refer to the Customizing Header Banners section.
The element represents a specific colour scheme. Its name must be the same as the color scheme directory name. This element has two following attributes:
idattribute contains the name of a color scheme.
captionattribute contains the description of a color scheme. This can be any text of your choice, e.g. "Green color scheme".
(Optional) This element describes properties of the template. Currently, these properties are just assigned to the template, but in the next version of Sitebuilder, the properties will be displayed to the end users selecting a template for their site.
compatibility element has its own child elements:
The element has the child element
minwidth, which contains minimal width of a template without horizontal scrolling.
browserselement contains the list of browsers' names and versions compatible to the template.
If you create the template specifically for certain Sitebuilder modules, specify names of the intended modules in this section.
modules element can have the following values: