WebTemp.xml

This content is outdated and is no longer being maintained. It is provided as a courtesy for individuals who are still using these technologies. This page may contain URLs that were valid when originally published, but now link to sites or pages that no longer exist.

Each front-end Web server in a deployment of Windows SharePoint Services has at least the originally installed WebTemp.xml file located in the Local_Drive:\Program Files\Common Files\Microsoft Shared\Web Server Extensions\12\TEMPLATE\LCID\XML folder, where LCID is the numeric ID of the language/culture, such as 1033 for English. There may also be one or more custom WebTemp*.xml files. The WebTemp*.xml files contain the site definition configurations that are available on the Template Selection section of the New SharePoint Site page.

Warning

You must create a custom site definition by copying an existing site definition and adding a WebTemp*.xml file that defines custom definition configurations for instantiating sites, rather than modifying the original WebTemp.xml file that is installed with Windows SharePoint Services. Changes that you make to originally installed files may be overwritten when you install updates or service packs to Windows SharePoint Services, or when you upgrade an installation to the next product version. For more information about creating a custom site definition, see How to: Create a Custom Site Definition and Configuration.

File Format

The Templates element specifies the site definitions being made available in the WebTemp*.xml file. Each site definition is defined with a Template element. Each site definition has one or more site definition configurations that can be used to instantiate sites. Each Template element specifies a unique ID and a name that corresponds to a site definition subfolder within the Local_Drive:\Program Files\Common Files\Microsoft Shared\Web Server Extensions\12\TEMPLATE\SiteTemplates folder.

A Template element can contain any number of Configuration child elements. Each such child represents a site definition configuration. The ID attribute of each Configuration element corresponds to the ID of another Configuration element that is in an Onet.xml file. The second Configuration element specifies the lists and modules of the site definition configuration.

Each Configuration element in a WebTemp*.xml file also specifies the title, the description, the virtual path to the image that is displayed in the Template Selection section of the New SharePoint Site page, and the tab in the selection box on which the site definition configuration will appear. A configuration can be hidden from the user interface (UI) by setting its Hidden attribute to TRUE.

Note

When Windows SharePoint Services 3.0 ships there are two tabs on the selection box in the Template Selection section of the New SharePoint Site page: "Collaboration" and "Meetings". If you create a custom site template by saving an existing site as a template, then a third tab, called "Custom" will appear in the box. If you use any value other than "Collaboration", "Meetings", or "Custom" as the value of the DisplayCategory attribute of a Configuration element in a WebTemp*.xml file, then a new tab with the new value as its name will appear in the box.

The following excerpt shows the format of a WebTemp.xml file.

<Templates 
  xmlns:ows="Microsoft SharePoint">
  <Template 
    Name="STS" 
    ID="1">
    <Configuration 
      ID="0" 
      Title="Team Site" 
      Hidden="FALSE" 
      ImageUrl="/_layouts/images/stsprev.png" 
      Description="A site for teams to quickly organize, author, and share information. It provides a document library, and lists for managing announcements, calendar items, tasks, and discussions." 
      DisplayCategory="Collaboration" />
    ...
    <Configuration 
      ID="2" 
      Title="Document Workspace" 
      Hidden="FALSE" 
      ImageUrl="/_layouts/images/dwsprev.png" 
      Description="A site for colleagues to work together on a document. It provides a document library for storing the primary document and supporting files, a tasks list for assigning to-do items, and a links list for resources related to the document." 
      DisplayCategory="Collaboration" />
  </Template>
  <Template 
    Name="MPS" 
    ID="2">
    <Configuration 
      ID="0" 
      Title="Basic Meeting Workspace" 
      Hidden="FALSE" 
      ImageUrl="/_layouts/images/mwsprev.png" 
      Description="All the basics to plan, organize and track your 
         meeting. This Meeting Workspace contains the following lists: 
         Objectives, Attendees, Agenda, and Document Library." 
      DisplayCategory="Meetings" />
    ...
  </Template>
</Templates>

For information about creating a custom definition configuration, see How to: Use Site Definition Configurations.